@telora/daemon 0.24.25 → 0.24.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build-info.json +9 -3
- package/dist/audit/audit-prompt.d.ts.map +1 -1
- package/dist/audit/audit-prompt.js +15 -0
- package/dist/audit/audit-prompt.js.map +1 -1
- package/dist/completion/completion-event/event.d.ts +4 -3
- package/dist/completion/completion-event/event.d.ts.map +1 -1
- package/dist/completion/completion-event/event.js.map +1 -1
- package/dist/completion/review-cycle-budget/review-cycle-cap.d.ts +19 -11
- package/dist/completion/review-cycle-budget/review-cycle-cap.d.ts.map +1 -1
- package/dist/completion/review-cycle-budget/review-cycle-cap.js +36 -36
- package/dist/completion/review-cycle-budget/review-cycle-cap.js.map +1 -1
- package/dist/completion/review-cycle-budget/review-loop-detection.d.ts +101 -0
- package/dist/completion/review-cycle-budget/review-loop-detection.d.ts.map +1 -0
- package/dist/completion/review-cycle-budget/review-loop-detection.js +105 -0
- package/dist/completion/review-cycle-budget/review-loop-detection.js.map +1 -0
- package/dist/completion/review-cycle-budget/spent-budget-release.d.ts +70 -0
- package/dist/completion/review-cycle-budget/spent-budget-release.d.ts.map +1 -0
- package/dist/completion/review-cycle-budget/spent-budget-release.js +98 -0
- package/dist/completion/review-cycle-budget/spent-budget-release.js.map +1 -0
- package/dist/completion/review-exit/review-defect-detector.d.ts +71 -49
- package/dist/completion/review-exit/review-defect-detector.d.ts.map +1 -1
- package/dist/completion/review-exit/review-defect-detector.js +75 -69
- package/dist/completion/review-exit/review-defect-detector.js.map +1 -1
- package/dist/completion/review-exit/review-exit-attribution.d.ts +1 -1
- package/dist/completion/review-exit/review-exit-attribution.js +1 -1
- package/dist/completion/review-exit/review-exit-deps.d.ts +5 -2
- package/dist/completion/review-exit/review-exit-deps.d.ts.map +1 -1
- package/dist/completion/review-exit/review-exit-deps.js +1 -1
- package/dist/completion/review-exit/review-exit-evidence.d.ts +10 -1
- package/dist/completion/review-exit/review-exit-evidence.d.ts.map +1 -1
- package/dist/completion/review-exit/review-exit-evidence.js +17 -14
- package/dist/completion/review-exit/review-exit-evidence.js.map +1 -1
- package/dist/completion/review-exit/review-exit-foreign-findings.d.ts +1 -1
- package/dist/completion/review-exit/review-exit-foreign-findings.d.ts.map +1 -1
- package/dist/completion/review-exit/review-exit-phase.d.ts.map +1 -1
- package/dist/completion/review-exit/review-exit-phase.js +12 -8
- package/dist/completion/review-exit/review-exit-phase.js.map +1 -1
- package/dist/completion/state-cascade/review-next-step.d.ts +12 -3
- package/dist/completion/state-cascade/review-next-step.d.ts.map +1 -1
- package/dist/completion/state-cascade/review-next-step.js +10 -1
- package/dist/completion/state-cascade/review-next-step.js.map +1 -1
- package/dist/completion/state-cascade/standing-approval-convergence.d.ts +1 -1
- package/dist/completion/state-cascade/standing-approval-convergence.d.ts.map +1 -1
- package/dist/completion/state-cascade/standing-approval-convergence.js +10 -4
- package/dist/completion/state-cascade/standing-approval-convergence.js.map +1 -1
- package/dist/completion/state-cascade/state-cascade.d.ts +3 -0
- package/dist/completion/state-cascade/state-cascade.d.ts.map +1 -1
- package/dist/completion/state-cascade/state-cascade.js +16 -1
- package/dist/completion/state-cascade/state-cascade.js.map +1 -1
- package/dist/completion/team-exit/status-advance-phase.d.ts +1 -1
- package/dist/completion/team-exit/status-advance-phase.d.ts.map +1 -1
- package/dist/completion/team-exit/status-advance-phase.js +6 -4
- package/dist/completion/team-exit/status-advance-phase.js.map +1 -1
- package/dist/completion/team-outcome/apply-turn.d.ts.map +1 -1
- package/dist/completion/team-outcome/apply-turn.js +9 -4
- package/dist/completion/team-outcome/apply-turn.js.map +1 -1
- package/dist/completion/team-outcome/decide-turn-entry-rows.d.ts.map +1 -1
- package/dist/completion/team-outcome/decide-turn-entry-rows.js +28 -3
- package/dist/completion/team-outcome/decide-turn-entry-rows.js.map +1 -1
- package/dist/completion/team-outcome/decide.d.ts.map +1 -1
- package/dist/completion/team-outcome/decide.js +1 -0
- package/dist/completion/team-outcome/decide.js.map +1 -1
- package/dist/completion/team-outcome/exit-limits.d.ts +6 -0
- package/dist/completion/team-outcome/exit-limits.d.ts.map +1 -1
- package/dist/completion/team-outcome/exit-limits.js +6 -0
- package/dist/completion/team-outcome/exit-limits.js.map +1 -1
- package/dist/completion/team-outcome/exit-pipeline-state.d.ts +5 -0
- package/dist/completion/team-outcome/exit-pipeline-state.d.ts.map +1 -1
- package/dist/completion/team-outcome/exit-pipeline-state.js.map +1 -1
- package/dist/completion/team-teardown/session-hold-bounds.d.ts +10 -1
- package/dist/completion/team-teardown/session-hold-bounds.d.ts.map +1 -1
- package/dist/completion/team-teardown/session-hold-bounds.js +11 -0
- package/dist/completion/team-teardown/session-hold-bounds.js.map +1 -1
- package/dist/completion/team-teardown/session-hold.d.ts.map +1 -1
- package/dist/completion/team-teardown/session-hold.js +2 -0
- package/dist/completion/team-teardown/session-hold.js.map +1 -1
- package/dist/composition/engine-start-context.d.ts.map +1 -1
- package/dist/composition/engine-start-context.js +9 -1
- package/dist/composition/engine-start-context.js.map +1 -1
- package/dist/composition/execution-spawn-context.d.ts.map +1 -1
- package/dist/composition/execution-spawn-context.js +2 -0
- package/dist/composition/execution-spawn-context.js.map +1 -1
- package/dist/composition/judgement-contexts.d.ts.map +1 -1
- package/dist/composition/judgement-contexts.js +8 -2
- package/dist/composition/judgement-contexts.js.map +1 -1
- package/dist/composition/review-exit-context.d.ts.map +1 -1
- package/dist/composition/review-exit-context.js +2 -0
- package/dist/composition/review-exit-context.js.map +1 -1
- package/dist/composition/review-loop-context.d.ts +28 -0
- package/dist/composition/review-loop-context.d.ts.map +1 -0
- package/dist/composition/review-loop-context.js +147 -0
- package/dist/composition/review-loop-context.js.map +1 -0
- package/dist/composition/runtime-heartbeat-context.d.ts.map +1 -1
- package/dist/composition/runtime-heartbeat-context.js +8 -2
- package/dist/composition/runtime-heartbeat-context.js.map +1 -1
- package/dist/composition/spawn-pass-deps.d.ts.map +1 -1
- package/dist/composition/spawn-pass-deps.js +3 -0
- package/dist/composition/spawn-pass-deps.js.map +1 -1
- package/dist/composition/state-cascade-context.d.ts.map +1 -1
- package/dist/composition/state-cascade-context.js +3 -1
- package/dist/composition/state-cascade-context.js.map +1 -1
- package/dist/composition/tower-escalation-context.d.ts +12 -0
- package/dist/composition/tower-escalation-context.d.ts.map +1 -0
- package/dist/composition/tower-escalation-context.js +109 -0
- package/dist/composition/tower-escalation-context.js.map +1 -0
- package/dist/composition/workstation-intervals-context.d.ts +3 -0
- package/dist/composition/workstation-intervals-context.d.ts.map +1 -0
- package/dist/composition/workstation-intervals-context.js +33 -0
- package/dist/composition/workstation-intervals-context.js.map +1 -0
- package/dist/daemon-state/awaiting-slot.d.ts +18 -1
- package/dist/daemon-state/awaiting-slot.d.ts.map +1 -1
- package/dist/daemon-state/awaiting-slot.js +7 -0
- package/dist/daemon-state/awaiting-slot.js.map +1 -1
- package/dist/delivery/delivery-reconciler.d.ts +7 -7
- package/dist/delivery/recorded-concerns.d.ts +63 -28
- package/dist/delivery/recorded-concerns.d.ts.map +1 -1
- package/dist/delivery/recorded-concerns.js +72 -28
- package/dist/delivery/recorded-concerns.js.map +1 -1
- package/dist/directive/directive-queue.d.ts +8 -0
- package/dist/directive/directive-queue.d.ts.map +1 -1
- package/dist/directive/directive-queue.js +1 -1
- package/dist/directive/directive-queue.js.map +1 -1
- package/dist/focus/control-state.d.ts +6 -4
- package/dist/focus/control-state.d.ts.map +1 -1
- package/dist/focus/control-state.js +6 -4
- package/dist/focus/control-state.js.map +1 -1
- package/dist/focus/daemon-contexts-judgement.d.ts +6 -0
- package/dist/focus/daemon-contexts-judgement.d.ts.map +1 -1
- package/dist/focus/daemon-contexts.d.ts +6 -0
- package/dist/focus/daemon-contexts.d.ts.map +1 -1
- package/dist/focus/daemon-contexts.js.map +1 -1
- package/dist/focus/focus-engine.d.ts.map +1 -1
- package/dist/focus/focus-engine.js +3 -1
- package/dist/focus/focus-engine.js.map +1 -1
- package/dist/focus/focus-executor.d.ts.map +1 -1
- package/dist/focus/focus-executor.js +3 -2
- package/dist/focus/focus-executor.js.map +1 -1
- package/dist/focus/focus-loop-registry.d.ts.map +1 -1
- package/dist/focus/focus-loop-registry.js +42 -0
- package/dist/focus/focus-loop-registry.js.map +1 -1
- package/dist/focus/focus-poller-auto-advance.d.ts +4 -2
- package/dist/focus/focus-poller-auto-advance.d.ts.map +1 -1
- package/dist/focus/focus-poller-auto-advance.js +24 -18
- package/dist/focus/focus-poller-auto-advance.js.map +1 -1
- package/dist/focus/focus-poller-spawn.d.ts.map +1 -1
- package/dist/focus/focus-poller-spawn.js +8 -6
- package/dist/focus/focus-poller-spawn.js.map +1 -1
- package/dist/focus/heartbeat.d.ts +9 -2
- package/dist/focus/heartbeat.d.ts.map +1 -1
- package/dist/focus/heartbeat.js +9 -1
- package/dist/focus/heartbeat.js.map +1 -1
- package/dist/focus/pending-directive-gates.d.ts +14 -0
- package/dist/focus/pending-directive-gates.d.ts.map +1 -1
- package/dist/focus/pending-directive-gates.js +25 -1
- package/dist/focus/pending-directive-gates.js.map +1 -1
- package/dist/focus/pending-spawn-pass-deps.d.ts +7 -0
- package/dist/focus/pending-spawn-pass-deps.d.ts.map +1 -1
- package/dist/focus/pending-spawn-review-next-step.d.ts +1 -1
- package/dist/focus/pending-spawn-review-next-step.d.ts.map +1 -1
- package/dist/focus/pending-spawn-review-next-step.js +2 -0
- package/dist/focus/pending-spawn-review-next-step.js.map +1 -1
- package/dist/focus/ready-focus-team-work.d.ts +9 -4
- package/dist/focus/ready-focus-team-work.d.ts.map +1 -1
- package/dist/focus/ready-focus-team-work.js +14 -3
- package/dist/focus/ready-focus-team-work.js.map +1 -1
- package/dist/focus/verify-open-issues.d.ts +3 -2
- package/dist/focus/verify-open-issues.d.ts.map +1 -1
- package/dist/focus/verify-open-issues.js +6 -4
- package/dist/focus/verify-open-issues.js.map +1 -1
- package/dist/focus/workstation-intervals.d.ts +83 -0
- package/dist/focus/workstation-intervals.d.ts.map +1 -0
- package/dist/focus/workstation-intervals.js +81 -0
- package/dist/focus/workstation-intervals.js.map +1 -0
- package/dist/focus-stage-lifecycle/wedge-watchdog.d.ts +5 -2
- package/dist/focus-stage-lifecycle/wedge-watchdog.d.ts.map +1 -1
- package/dist/focus-stage-lifecycle/wedge-watchdog.js +2 -2
- package/dist/focus-stage-lifecycle/wedge-watchdog.js.map +1 -1
- package/dist/prompt-sections/persona-sections.d.ts.map +1 -1
- package/dist/prompt-sections/persona-sections.js +4 -1
- package/dist/prompt-sections/persona-sections.js.map +1 -1
- package/dist/prompt-sections/qa-author-section.d.ts.map +1 -1
- package/dist/prompt-sections/qa-author-section.js +18 -1
- package/dist/prompt-sections/qa-author-section.js.map +1 -1
- package/dist/prompt-sections/scoping-sections.d.ts +0 -12
- package/dist/prompt-sections/scoping-sections.d.ts.map +1 -1
- package/dist/prompt-sections/scoping-sections.js +16 -2
- package/dist/prompt-sections/scoping-sections.js.map +1 -1
- package/dist/prompts/bounded-universals.d.ts +13 -0
- package/dist/prompts/bounded-universals.d.ts.map +1 -0
- package/dist/prompts/bounded-universals.js +32 -0
- package/dist/prompts/bounded-universals.js.map +1 -0
- package/dist/queries/api-client/shared.d.ts +2 -1
- package/dist/queries/api-client/shared.d.ts.map +1 -1
- package/dist/queries/api-client/shared.js +31 -1
- package/dist/queries/api-client/shared.js.map +1 -1
- package/dist/queries/deliveries/issues.d.ts.map +1 -1
- package/dist/queries/deliveries/issues.js +1 -0
- package/dist/queries/deliveries/issues.js.map +1 -1
- package/dist/queries/escalations/escalation-consumption.d.ts +13 -0
- package/dist/queries/escalations/escalation-consumption.d.ts.map +1 -1
- package/dist/queries/escalations/escalation-consumption.js +12 -2
- package/dist/queries/escalations/escalation-consumption.js.map +1 -1
- package/dist/queries/escalations/tower-escalations.d.ts +82 -0
- package/dist/queries/escalations/tower-escalations.d.ts.map +1 -0
- package/dist/queries/escalations/tower-escalations.js +97 -0
- package/dist/queries/escalations/tower-escalations.js.map +1 -0
- package/dist/queries/focus-review/recorded-concern-ids.d.ts +48 -11
- package/dist/queries/focus-review/recorded-concern-ids.d.ts.map +1 -1
- package/dist/queries/focus-review/recorded-concern-ids.js +42 -12
- package/dist/queries/focus-review/recorded-concern-ids.js.map +1 -1
- package/dist/queries/focus-review/review-criterion-verdicts.d.ts +37 -0
- package/dist/queries/focus-review/review-criterion-verdicts.d.ts.map +1 -0
- package/dist/queries/focus-review/review-criterion-verdicts.js +64 -0
- package/dist/queries/focus-review/review-criterion-verdicts.js.map +1 -0
- package/dist/queries/focus-review/review-finding-facts.d.ts +18 -6
- package/dist/queries/focus-review/review-finding-facts.d.ts.map +1 -1
- package/dist/queries/focus-review/review-finding-facts.js +21 -8
- package/dist/queries/focus-review/review-finding-facts.js.map +1 -1
- package/dist/queries/focuses/ended-arm.d.ts +56 -13
- package/dist/queries/focuses/ended-arm.d.ts.map +1 -1
- package/dist/queries/focuses/ended-arm.js +40 -14
- package/dist/queries/focuses/ended-arm.js.map +1 -1
- package/dist/queries/focuses/focus-criteria-standing.d.ts +12 -0
- package/dist/queries/focuses/focus-criteria-standing.d.ts.map +1 -1
- package/dist/queries/focuses/focus-criteria-standing.js +13 -0
- package/dist/queries/focuses/focus-criteria-standing.js.map +1 -1
- package/dist/queries/focuses/focus-discovery.d.ts +14 -3
- package/dist/queries/focuses/focus-discovery.d.ts.map +1 -1
- package/dist/queries/focuses/focus-discovery.js +2 -19
- package/dist/queries/focuses/focus-discovery.js.map +1 -1
- package/dist/queries/focuses/focuses.d.ts +15 -12
- package/dist/queries/focuses/focuses.d.ts.map +1 -1
- package/dist/queries/focuses/focuses.js +15 -13
- package/dist/queries/focuses/focuses.js.map +1 -1
- package/dist/queries/sessions/sessions.d.ts.map +1 -1
- package/dist/queries/sessions/sessions.js +2 -1
- package/dist/queries/sessions/sessions.js.map +1 -1
- package/dist/queries/tower-decisions/tower-decisions.d.ts +103 -0
- package/dist/queries/tower-decisions/tower-decisions.d.ts.map +1 -0
- package/dist/queries/tower-decisions/tower-decisions.js +138 -0
- package/dist/queries/tower-decisions/tower-decisions.js.map +1 -0
- package/dist/queries/wire-schemas/schemas.d.ts +2 -0
- package/dist/queries/wire-schemas/schemas.d.ts.map +1 -1
- package/dist/queries/wire-schemas/schemas.js +8 -2
- package/dist/queries/wire-schemas/schemas.js.map +1 -1
- package/dist/queries/workstation-intervals/workstation-intervals.d.ts +52 -0
- package/dist/queries/workstation-intervals/workstation-intervals.d.ts.map +1 -0
- package/dist/queries/workstation-intervals/workstation-intervals.js +49 -0
- package/dist/queries/workstation-intervals/workstation-intervals.js.map +1 -0
- package/dist/resolvers/escalation-answers.d.ts +31 -0
- package/dist/resolvers/escalation-answers.d.ts.map +1 -1
- package/dist/resolvers/escalation-answers.js +31 -17
- package/dist/resolvers/escalation-answers.js.map +1 -1
- package/dist/resolvers/focus-criteria-standing.d.ts.map +1 -1
- package/dist/resolvers/focus-criteria-standing.js +20 -0
- package/dist/resolvers/focus-criteria-standing.js.map +1 -1
- package/dist/shell/unified-engine-lifecycle.d.ts +11 -1
- package/dist/shell/unified-engine-lifecycle.d.ts.map +1 -1
- package/dist/shell/unified-engine-lifecycle.js +10 -1
- package/dist/shell/unified-engine-lifecycle.js.map +1 -1
- package/dist/spawn/directive-dispatch.d.ts.map +1 -1
- package/dist/spawn/directive-dispatch.js +1 -0
- package/dist/spawn/directive-dispatch.js.map +1 -1
- package/dist/spawn/lead-continuation.d.ts +4 -3
- package/dist/spawn/lead-continuation.d.ts.map +1 -1
- package/dist/spawn/lead-continuation.js.map +1 -1
- package/dist/spawn/live-answer-delivery.d.ts +53 -0
- package/dist/spawn/live-answer-delivery.d.ts.map +1 -0
- package/dist/spawn/live-answer-delivery.js +26 -0
- package/dist/spawn/live-answer-delivery.js.map +1 -0
- package/dist/spawn/routing-decider-spawn.d.ts +64 -2
- package/dist/spawn/routing-decider-spawn.d.ts.map +1 -1
- package/dist/spawn/routing-decider-spawn.js +65 -20
- package/dist/spawn/routing-decider-spawn.js.map +1 -1
- package/dist/spawn/worktree-session.d.ts +7 -5
- package/dist/spawn/worktree-session.d.ts.map +1 -1
- package/dist/spawn/worktree-session.js +11 -7
- package/dist/spawn/worktree-session.js.map +1 -1
- package/dist/supervision/review-cycle-cap-hold.d.ts +11 -5
- package/dist/supervision/review-cycle-cap-hold.d.ts.map +1 -1
- package/dist/supervision/review-cycle-cap-hold.js +29 -11
- package/dist/supervision/review-cycle-cap-hold.js.map +1 -1
- package/dist/supervision/review-loop-detector.d.ts +48 -0
- package/dist/supervision/review-loop-detector.d.ts.map +1 -0
- package/dist/supervision/review-loop-detector.js +13 -0
- package/dist/supervision/review-loop-detector.js.map +1 -0
- package/dist/supervision/review-loop-hold.d.ts +29 -0
- package/dist/supervision/review-loop-hold.d.ts.map +1 -0
- package/dist/supervision/review-loop-hold.js +99 -0
- package/dist/supervision/review-loop-hold.js.map +1 -0
- package/dist/supervision/stall-detector-config.d.ts +8 -0
- package/dist/supervision/stall-detector-config.d.ts.map +1 -1
- package/dist/supervision/stall-detector-config.js +14 -3
- package/dist/supervision/stall-detector-config.js.map +1 -1
- package/dist/supervision/stop-registry.d.ts +3 -0
- package/dist/supervision/stop-registry.d.ts.map +1 -1
- package/dist/supervision/stop-registry.js +3 -1
- package/dist/supervision/stop-registry.js.map +1 -1
- package/dist/supervision/stop-rows-review-loop.d.ts +35 -0
- package/dist/supervision/stop-rows-review-loop.d.ts.map +1 -0
- package/dist/supervision/stop-rows-review-loop.js +150 -0
- package/dist/supervision/stop-rows-review-loop.js.map +1 -0
- package/dist/supervision/stop-rows-team-session.d.ts +1 -1
- package/dist/supervision/stop-rows-team-session.d.ts.map +1 -1
- package/dist/supervision/stop-rows-team-session.js.map +1 -1
- package/dist/supervision/unreviewed-settle-detector.d.ts +7 -2
- package/dist/supervision/unreviewed-settle-detector.d.ts.map +1 -1
- package/dist/supervision/unreviewed-settle-detector.js +15 -2
- package/dist/supervision/unreviewed-settle-detector.js.map +1 -1
- package/dist/templates/agents-md.d.ts.map +1 -1
- package/dist/templates/agents-md.js +1 -0
- package/dist/templates/agents-md.js.map +1 -1
- package/dist/templates/claude-md.d.ts +1 -1
- package/dist/templates/claude-md.d.ts.map +1 -1
- package/dist/templates/claude-md.js +12 -0
- package/dist/templates/claude-md.js.map +1 -1
- package/dist/testing/fixtures/api-client.js +1 -1
- package/dist/testing/fixtures/index.js +1 -1
- package/dist/testing/fixtures/pending-spawn-world.d.ts +4 -0
- package/dist/testing/fixtures/pending-spawn-world.d.ts.map +1 -1
- package/dist/testing/fixtures/pending-spawn-world.js +15 -2
- package/dist/testing/fixtures/pending-spawn-world.js.map +1 -1
- package/dist/testing/fixtures/recording-api-client.js +1 -1
- package/dist/testing/fixtures/review-exit-deps.d.ts.map +1 -1
- package/dist/testing/fixtures/review-exit-deps.js +3 -1
- package/dist/testing/fixtures/review-exit-deps.js.map +1 -1
- package/dist/testing/fixtures/review-loop.d.ts +19 -0
- package/dist/testing/fixtures/review-loop.d.ts.map +1 -0
- package/dist/testing/fixtures/review-loop.js +30 -0
- package/dist/testing/fixtures/review-loop.js.map +1 -0
- package/dist/testing/fixtures/shortfall-rework-hold-deps.d.ts.map +1 -1
- package/dist/testing/fixtures/shortfall-rework-hold-deps.js +1 -0
- package/dist/testing/fixtures/shortfall-rework-hold-deps.js.map +1 -1
- package/dist/testing/fixtures/tower-loop.d.ts +28 -0
- package/dist/testing/fixtures/tower-loop.d.ts.map +1 -0
- package/dist/testing/fixtures/tower-loop.js +83 -0
- package/dist/testing/fixtures/tower-loop.js.map +1 -0
- package/dist/tower/tower-escalation-gather.d.ts +33 -0
- package/dist/tower/tower-escalation-gather.d.ts.map +1 -0
- package/dist/tower/tower-escalation-gather.js +38 -0
- package/dist/tower/tower-escalation-gather.js.map +1 -0
- package/dist/tower/tower-escalation-prompt.d.ts +62 -0
- package/dist/tower/tower-escalation-prompt.d.ts.map +1 -0
- package/dist/tower/tower-escalation-prompt.js +130 -0
- package/dist/tower/tower-escalation-prompt.js.map +1 -0
- package/dist/tower/tower-escalation-routing.d.ts +49 -0
- package/dist/tower/tower-escalation-routing.d.ts.map +1 -0
- package/dist/tower/tower-escalation-routing.js +53 -0
- package/dist/tower/tower-escalation-routing.js.map +1 -0
- package/dist/tower/tower-escalation-session.d.ts +149 -0
- package/dist/tower/tower-escalation-session.d.ts.map +1 -0
- package/dist/tower/tower-escalation-session.js +238 -0
- package/dist/tower/tower-escalation-session.js.map +1 -0
- package/dist/tower/tower-supervisor-history.d.ts +129 -0
- package/dist/tower/tower-supervisor-history.d.ts.map +1 -0
- package/dist/tower/tower-supervisor-history.js +217 -0
- package/dist/tower/tower-supervisor-history.js.map +1 -0
- package/dist/tower/tower-supervisor-prompt.d.ts +21 -0
- package/dist/tower/tower-supervisor-prompt.d.ts.map +1 -0
- package/dist/tower/tower-supervisor-prompt.js +205 -0
- package/dist/tower/tower-supervisor-prompt.js.map +1 -0
- package/dist/tower/tower-supervisor-session.d.ts +220 -0
- package/dist/tower/tower-supervisor-session.d.ts.map +1 -0
- package/dist/tower/tower-supervisor-session.js +307 -0
- package/dist/tower/tower-supervisor-session.js.map +1 -0
- package/dist/tower/tower-supervisor.d.ts +86 -0
- package/dist/tower/tower-supervisor.d.ts.map +1 -0
- package/dist/tower/tower-supervisor.js +8 -0
- package/dist/tower/tower-supervisor.js.map +1 -0
- package/dist/types/index.js +1 -1
- package/dist/verify/outcome-routing/verification-rework-issue.d.ts +4 -4
- package/dist/verify/outcome-routing/verification-rework-issue.d.ts.map +1 -1
- package/dist/verify/outcome-routing/verification-rework-issue.js +16 -6
- package/dist/verify/outcome-routing/verification-rework-issue.js.map +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pending-spawn-world.js","sourceRoot":"","sources":["../../../src/testing/fixtures/pending-spawn-world.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,gHAAgH;AAChH,4FAA4F;AAC5F,2EAA2E;AAC3E,kEAAkE;AAClE,uEAAuE;AACvE,8DAA8D;AAC9D,oEAAoE;AACpE,sEAAsE;AACtE,+DAA+D;AAC/D,iEAAiE;AACjE,2FAA2F;AAC3F,gGAAgG;AAChG,mFAAmF;AACnF,2FAA2F;AAC3F,mFAAmF;AACnF,gFAAgF;AAChF,iEAAiE;AACjE,gBAAgB;AAEhB;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAMzC,OAAO,EAAE,4BAA4B,EAAE,MAAM,oCAAoC,CAAC;AAClF,OAAO,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AACxE,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,EAAE,6BAA6B,EAAE,MAAM,oCAAoC,CAAC;AACnF,OAAO,EAAE,mBAAmB,EAAE,MAAM,qCAAqC,CAAC;
|
|
1
|
+
{"version":3,"file":"pending-spawn-world.js","sourceRoot":"","sources":["../../../src/testing/fixtures/pending-spawn-world.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,gHAAgH;AAChH,4FAA4F;AAC5F,2EAA2E;AAC3E,kEAAkE;AAClE,uEAAuE;AACvE,8DAA8D;AAC9D,oEAAoE;AACpE,sEAAsE;AACtE,+DAA+D;AAC/D,iEAAiE;AACjE,2FAA2F;AAC3F,gGAAgG;AAChG,mFAAmF;AACnF,2FAA2F;AAC3F,mFAAmF;AACnF,gFAAgF;AAChF,iEAAiE;AACjE,gBAAgB;AAEhB;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,+BAA+B,EAAE,MAAM,qCAAqC,CAAC;AACtF,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW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AG,cAAc,CAAC,KAAK,CAAC,CAAC;IACpC,OAAO;QACL,kBAAkB,EAAE,KAAK,CAAC,kBAAkB;QAC5C,cAAc,EAAE,KAAK,CAAC,cAAc;QACpC,sBAAsB,EAAE,sBAAsB,CAAC,KAAK,CAAC;QACrD,oBAAoB,EAAE,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,EAAE;YACrD,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;YAC1B,KAAK,CAAC,GAAG,GAAG,EAAE,GAAG,KAAK,CAAC,GAAG,EAAE,mBAAmB,EAAE,YAAY,EAAE,CAAC;QAClE,CAAC;QACD,sBAAsB,EAAE,KAAK,IAAI,EAAE;YACjC,KAAK,CAAC,GAAG,GAAG,EAAE,GAAG,KAAK,CAAC,GAAG,EAAE,mBAAmB,EAAE,IAAI,EAAE,CAAC;QAC1D,CAAC;QACD,qBAAqB,EAAE,GAAG,EAAE,CAAC,KAAK;QAClC,gBAAgB,EAAE,KAAK,IAAI,EAAE,GAAE,CAAC;QAChC,eAAe,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,MAAe,EAAE,CAAC;KAC1D,CAAC;AACJ,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// PINNED-BY-BEGIN (generated by gen:pinned-by -- do not hand-edit; checked by lint:pinned-by)
|
|
2
|
-
// Pinned by:
|
|
2
|
+
// Pinned by: 36 tests -- run: npm run gen:pinned-by -- --list packages/daemon/src/testing/fixtures/recording-api-client.ts
|
|
3
3
|
// PINNED-BY-END
|
|
4
4
|
/**
|
|
5
5
|
* Test fixture: install a RECORDING fake product-api client -- every call is
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"review-exit-deps.d.ts","sourceRoot":"","sources":["../../../src/testing/fixtures/review-exit-deps.ts"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;
|
|
1
|
+
{"version":3,"file":"review-exit-deps.d.ts","sourceRoot":"","sources":["../../../src/testing/fixtures/review-exit-deps.ts"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;AAGvF,6EAA6E;AAC7E,wBAAgB,kBAAkB,CAAC,SAAS,GAAE,OAAO,CAAC,cAAc,CAAM,GAAG,cAAc,CAgD1F"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
// PINNED-BY-BEGIN (generated by gen:pinned-by -- do not hand-edit; checked by lint:pinned-by)
|
|
2
|
-
// Pinned by:
|
|
2
|
+
// Pinned by: 60 tests -- run: npm run gen:pinned-by -- --list packages/daemon/src/testing/fixtures/review-exit-deps.ts
|
|
3
3
|
// PINNED-BY-END
|
|
4
|
+
import { inertReviewLoopDetectionDeps } from './review-loop.js';
|
|
4
5
|
/** A complete inert review-exit context, with `overrides` spread over it. */
|
|
5
6
|
export function makeReviewExitDeps(overrides = {}) {
|
|
6
7
|
return {
|
|
@@ -24,6 +25,7 @@ export function makeReviewExitDeps(overrides = {}) {
|
|
|
24
25
|
resolveReviewCycleCap: () => Number.MAX_SAFE_INTEGER,
|
|
25
26
|
releaseFocusArm: async () => { },
|
|
26
27
|
isShuttingDown: () => false,
|
|
28
|
+
reviewLoop: inertReviewLoopDetectionDeps(),
|
|
27
29
|
setReviewHandoffCount: async () => { },
|
|
28
30
|
resolveReviewHandoffCap: () => Number.MAX_SAFE_INTEGER,
|
|
29
31
|
resolveHandoffExhaustedHold: async () => 0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"review-exit-deps.js","sourceRoot":"","sources":["../../../src/testing/fixtures/review-exit-deps.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,uHAAuH;AACvH,gBAAgB;
|
|
1
|
+
{"version":3,"file":"review-exit-deps.js","sourceRoot":"","sources":["../../../src/testing/fixtures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E,cAAc,EAAE,IAAI,GAAG,EAAE,EAAE,CAAC;QACrF,gBAAgB,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,YAAY,EAAE,IAAI,EAAE,CAAC;QACtD,GAAG,SAAS;KACb,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Inert non-converging review-loop collaborators: no reviews, no decisions, a
|
|
3
|
+
* supervisor that is never called, and a hold read that answers no open loops.
|
|
4
|
+
* Every review-exit and spawn-gate fixture that does not exercise the loop
|
|
5
|
+
* binds these, so the loop machinery is present (its deps are required) and
|
|
6
|
+
* decides nothing.
|
|
7
|
+
*
|
|
8
|
+
* @module testing/fixtures/review-loop
|
|
9
|
+
*/
|
|
10
|
+
import type { ReviewLoopDetectionDeps } from '../../completion/review-cycle-budget/review-loop-detection.js';
|
|
11
|
+
import type { ReviewLoopHoldDeps } from '../../supervision/review-loop-hold.js';
|
|
12
|
+
import { type TowerSupervisor } from '../../tower/tower-supervisor.js';
|
|
13
|
+
/** A supervisor that decides nothing and sweeps nothing. */
|
|
14
|
+
export declare const INERT_TOWER_SUPERVISOR: TowerSupervisor;
|
|
15
|
+
/** Detection deps that read nothing and record nothing (any write throws: an inert fixture must not be written through). */
|
|
16
|
+
export declare function inertReviewLoopDetectionDeps(overrides?: Partial<ReviewLoopDetectionDeps>): ReviewLoopDetectionDeps;
|
|
17
|
+
/** A hold read that answers no open loops. */
|
|
18
|
+
export declare const NO_REVIEW_LOOPS: ReviewLoopHoldDeps;
|
|
19
|
+
//# sourceMappingURL=review-loop.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"review-loop.d.ts","sourceRoot":"","sources":["../../../src/testing/fixtures/review-loop.ts"],"names":[],"mappings":"AASA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,+DAA+D,CAAC;AAC7G,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,uCAAuC,CAAC;AAChF,OAAO,EAAoB,KAAK,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAEzF,4DAA4D;AAC5D,eAAO,MAAM,sBAAsB,EAAE,eAGpC,CAAC;AAEF,4HAA4H;AAC5H,wBAAgB,4BAA4B,CAAC,SAAS,GAAE,OAAO,CAAC,uBAAuB,CAAM,GAAG,uBAAuB,CAWtH;AAED,8CAA8C;AAC9C,eAAO,MAAM,eAAe,EAAE,kBAA4D,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// PINNED-BY-BEGIN (generated by gen:pinned-by -- do not hand-edit; checked by lint:pinned-by)
|
|
2
|
+
// Pinned by: packages/daemon/src/completion/review-cycle-budget/review-cycle-cap-regression.test.ts,
|
|
3
|
+
// packages/daemon/src/completion/review-cycle-budget/review-loop-detection.test.ts,
|
|
4
|
+
// packages/daemon/src/focus/awaiting-slot.test.ts,
|
|
5
|
+
// packages/daemon/src/integration/review-request-verdict-composed.test.ts,
|
|
6
|
+
// packages/daemon/src/supervision/review-cycle-cap-hold.test.ts,
|
|
7
|
+
// packages/daemon/src/tower/tower-entrypoints.test.ts, packages/daemon/src/tower/tower-spawn-modes.test.ts
|
|
8
|
+
// PINNED-BY-END
|
|
9
|
+
import { emptySweepCounts } from '../../tower/tower-supervisor.js';
|
|
10
|
+
/** A supervisor that decides nothing and sweeps nothing. */
|
|
11
|
+
export const INERT_TOWER_SUPERVISOR = {
|
|
12
|
+
onLoopDetected: async () => { },
|
|
13
|
+
sweep: async () => emptySweepCounts(),
|
|
14
|
+
};
|
|
15
|
+
/** Detection deps that read nothing and record nothing (any write throws: an inert fixture must not be written through). */
|
|
16
|
+
export function inertReviewLoopDetectionDeps(overrides = {}) {
|
|
17
|
+
return {
|
|
18
|
+
listReviewCriterionVerdicts: async () => [],
|
|
19
|
+
listTowerDecisions: async () => ({ decisions: [], openLoopDecisionIds: [] }),
|
|
20
|
+
recordTowerDecision: async () => {
|
|
21
|
+
throw new Error('inertReviewLoopDetectionDeps: recordTowerDecision is not stubbed -- supply it in the overrides');
|
|
22
|
+
},
|
|
23
|
+
resolveReviewLoopThreshold: () => 3,
|
|
24
|
+
towerSupervisor: INERT_TOWER_SUPERVISOR,
|
|
25
|
+
...overrides,
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
/** A hold read that answers no open loops. */
|
|
29
|
+
export const NO_REVIEW_LOOPS = { listOpenReviewLoops: async () => [] };
|
|
30
|
+
//# sourceMappingURL=review-loop.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"review-loop.js","sourceRoot":"","sources":["../../../src/testing/fixtures/review-loop.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,qGAAqG;AACrG,sFAAsF;AACtF,qDAAqD;AACrD,6EAA6E;AAC7E,mEAAmE;AACnE,6GAA6G;AAC7G,gBAAgB;AAchB,OAAO,EAAE,gBAAgB,EAAwB,MAAM,iCAAiC,CAAC;AAEzF,4DAA4D;AAC5D,MAAM,CAAC,MAAM,sBAAsB,GAAoB;IACrD,cAAc,EAAE,KAAK,IAAI,EAAE,GAAE,CAAC;IAC9B,KAAK,EAAE,KAAK,IAAI,EAAE,CAAC,gBAAgB,EAAE;CACtC,CAAC;AAEF,4HAA4H;AAC5H,MAAM,UAAU,4BAA4B,CAAC,YAA8C,EAAE;IAC3F,OAAO;QACL,2BAA2B,EAAE,KAAK,IAAI,EAAE,CAAC,EAAE;QAC3C,kBAAkB,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,SAAS,EAAE,EAAE,EAAE,mBAAmB,EAAE,EAAE,EAAE,CAAC;QAC5E,mBAAmB,EAAE,KAAK,IAAI,EAAE;YAC9B,MAAM,IAAI,KAAK,CAAC,gGAAgG,CAAC,CAAC;QACpH,CAAC;QACD,0BAA0B,EAAE,GAAG,EAAE,CAAC,CAAC;QACnC,eAAe,EAAE,sBAAsB;QACvC,GAAG,SAAS;KACb,CAAC;AACJ,CAAC;AAED,8CAA8C;AAC9C,MAAM,CAAC,MAAM,eAAe,GAAuB,EAAE,mBAAmB,EAAE,KAAK,IAAI,EAAE,CAAC,EAAE,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shortfall-rework-hold-deps.d.ts","sourceRoot":"","sources":["../../../src/testing/fixtures/shortfall-rework-hold-deps.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"shortfall-rework-hold-deps.d.ts","sourceRoot":"","sources":["../../../src/testing/fixtures/shortfall-rework-hold-deps.ts"],"names":[],"mappings":"AAaA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAEL,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC7B,MAAM,kDAAkD,CAAC;AAE1D,mEAAmE;AACnE,wBAAgB,4BAA4B,CAAC,SAAS,GAAE,OAAO,CAAC,uBAAuB,CAAM,GAAG,uBAAuB,CAUtH;AAED,+FAA+F;AAC/F,wBAAgB,wBAAwB,CAAC,SAAS,GAAE,OAAO,CAAC,uBAAuB,CAAM,GAAG,uBAAuB,CAElH"}
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
// packages/daemon/src/focus/recorded-delivery-auto-advance.test.ts,
|
|
6
6
|
// packages/daemon/src/focus/unarmed-advance-hold.test.ts,
|
|
7
7
|
// packages/daemon/src/integration/advancement-path-parity.test.ts,
|
|
8
|
+
// packages/daemon/src/integration/f114-review-concern-never-holds-done-regression.test.ts,
|
|
8
9
|
// packages/daemon/src/integration/last-shortfall-judgment-round-trip.test.ts,
|
|
9
10
|
// packages/daemon/src/integration/verification-history-round-trip.test.ts,
|
|
10
11
|
// packages/daemon/src/verify/shortfalls/shortfall-rework-hold.test.ts
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shortfall-rework-hold-deps.js","sourceRoot":"","sources":["../../../src/testing/fixtures/shortfall-rework-hold-deps.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,gEAAgE;AAChE,sEAAsE;AACtE,4DAA4D;AAC5D,sEAAsE;AACtE,4DAA4D;AAC5D,qEAAqE;AACrE,gFAAgF;AAChF,6EAA6E;AAC7E,wEAAwE;AACxE,gBAAgB;AAEhB;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACL,uBAAuB,GAGxB,MAAM,kDAAkD,CAAC;AAE1D,mEAAmE;AACnE,MAAM,UAAU,4BAA4B,CAAC,YAA8C,EAAE;IAC3F,OAAO;QACL,aAAa,EAAE,GAAG,EAAE,CAAC,IAAI;QACzB,WAAW,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;QAC3D,WAAW,EAAE,GAAG,EAAE,CAAC,KAAK;QACxB,WAAW,EAAE,KAAK,IAAI,EAAE,CAAC,uBAAuB;QAChD,iBAAiB,EAAE,KAAK,IAAI,EAAE,GAAE,CAAC;QACjC,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC;QACZ,GAAG,SAAS;KACb,CAAC;AACJ,CAAC;AAED,+FAA+F;AAC/F,MAAM,UAAU,wBAAwB,CAAC,YAA8C,EAAE;IACvF,OAAO,uBAAuB,CAAC,4BAA4B,CAAC,SAAS,CAAC,CAAC,CAAC;AAC1E,CAAC"}
|
|
1
|
+
{"version":3,"file":"shortfall-rework-hold-deps.js","sourceRoot":"","sources":["../../../src/testing/fixtures/shortfall-rework-hold-deps.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,gEAAgE;AAChE,sEAAsE;AACtE,4DAA4D;AAC5D,sEAAsE;AACtE,4DAA4D;AAC5D,qEAAqE;AACrE,6FAA6F;AAC7F,gFAAgF;AAChF,6EAA6E;AAC7E,wEAAwE;AACxE,gBAAgB;AAEhB;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACL,uBAAuB,GAGxB,MAAM,kDAAkD,CAAC;AAE1D,mEAAmE;AACnE,MAAM,UAAU,4BAA4B,CAAC,YAA8C,EAAE;IAC3F,OAAO;QACL,aAAa,EAAE,GAAG,EAAE,CAAC,IAAI;QACzB,WAAW,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;QAC3D,WAAW,EAAE,GAAG,EAAE,CAAC,KAAK;QACxB,WAAW,EAAE,KAAK,IAAI,EAAE,CAAC,uBAAuB;QAChD,iBAAiB,EAAE,KAAK,IAAI,EAAE,GAAE,CAAC;QACjC,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC;QACZ,GAAG,SAAS;KACb,CAAC;AACJ,CAAC;AAED,+FAA+F;AAC/F,MAAM,UAAU,wBAAwB,CAAC,YAA8C,EAAE;IACvF,OAAO,uBAAuB,CAAC,4BAA4B,CAAC,SAAS,CAAC,CAAC,CAAC;AAC1E,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A held review loop in the shape of Tinker Tailor f114 (escalation c1b8cae9):
|
|
3
|
+
* one criterion -- "TARA says a held piece can be made shorter or longer only
|
|
4
|
+
* when a shorter or longer piece exists for the design as it stands." -- not met
|
|
5
|
+
* on three consecutive reviews, each naming one new blocking Bug against it,
|
|
6
|
+
* every other criterion met. The operator bounded it by hand into 13 closed
|
|
7
|
+
* claim forms held by tests plus the TARA battery LLM grader for the rest; the
|
|
8
|
+
* Tower supervisor is the actor that now does that.
|
|
9
|
+
*
|
|
10
|
+
* @module testing/fixtures/tower-loop
|
|
11
|
+
*/
|
|
12
|
+
import type { TowerDecision } from '../../queries/tower-decisions/tower-decisions.js';
|
|
13
|
+
import type { ReviewVerdictRecord } from '../../queries/focus-review/review-criterion-verdicts.js';
|
|
14
|
+
import type { FocusIssueInfo } from '../../types/index.js';
|
|
15
|
+
export declare const F114_FOCUS_ID = "11400000-0000-4000-8000-000000000001";
|
|
16
|
+
export declare const F114_PRODUCT_ID = "11400000-0000-4000-8000-0000000000a1";
|
|
17
|
+
export declare const F114_LOOP_ID = "11400000-0000-4000-8000-0000000000d1";
|
|
18
|
+
export declare const F114_NODE_ID = "11400000-0000-4000-8000-0000000000e1";
|
|
19
|
+
export declare const F114_DELIVERY_ID = "11400000-0000-4000-8000-0000000000b1";
|
|
20
|
+
export declare const F114_CRITERION = "TARA says a held piece can be made shorter or longer only when a shorter or longer piece exists for the design as it stands.";
|
|
21
|
+
export declare const F114_CRITERION_KEY = "node:11400000-0000-4000-8000-0000000000e1";
|
|
22
|
+
/** The loop_detected decision the review exit recorded. */
|
|
23
|
+
export declare function f114LoopDecision(over?: Partial<TowerDecision>): TowerDecision;
|
|
24
|
+
/** The three reviews as the verdict read answers them (newest first). */
|
|
25
|
+
export declare function f114Reviews(): ReviewVerdictRecord[];
|
|
26
|
+
/** The blocking Bugs the reviews filed. */
|
|
27
|
+
export declare function f114Issues(): FocusIssueInfo[];
|
|
28
|
+
//# sourceMappingURL=tower-loop.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tower-loop.d.ts","sourceRoot":"","sources":["../../../src/testing/fixtures/tower-loop.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kDAAkD,CAAC;AACtF,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,yDAAyD,CAAC;AACnG,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,eAAO,MAAM,aAAa,yCAAyC,CAAC;AACpE,eAAO,MAAM,eAAe,yCAAyC,CAAC;AACtE,eAAO,MAAM,YAAY,yCAAyC,CAAC;AACnE,eAAO,MAAM,YAAY,yCAAyC,CAAC;AACnE,eAAO,MAAM,gBAAgB,yCAAyC,CAAC;AACvE,eAAO,MAAM,cAAc,iIACqG,CAAC;AACjI,eAAO,MAAM,kBAAkB,8CAAyB,CAAC;AAQzD,2DAA2D;AAC3D,wBAAgB,gBAAgB,CAAC,IAAI,GAAE,OAAO,CAAC,aAAa,CAAM,GAAG,aAAa,CA4BjF;AAED,yEAAyE;AACzE,wBAAgB,WAAW,IAAI,mBAAmB,EAAE,CAcnD;AAED,2CAA2C;AAC3C,wBAAgB,UAAU,IAAI,cAAc,EAAE,CAiB7C"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
// PINNED-BY-BEGIN (generated by gen:pinned-by -- do not hand-edit; checked by lint:pinned-by)
|
|
2
|
+
// Pinned by: packages/daemon/src/tower/tower-supervisor-history.test.ts,
|
|
3
|
+
// packages/daemon/src/tower/tower-supervisor-prompt.test.ts,
|
|
4
|
+
// packages/daemon/src/tower/tower-supervisor-session.test.ts
|
|
5
|
+
// PINNED-BY-END
|
|
6
|
+
export const F114_FOCUS_ID = '11400000-0000-4000-8000-000000000001';
|
|
7
|
+
export const F114_PRODUCT_ID = '11400000-0000-4000-8000-0000000000a1';
|
|
8
|
+
export const F114_LOOP_ID = '11400000-0000-4000-8000-0000000000d1';
|
|
9
|
+
export const F114_NODE_ID = '11400000-0000-4000-8000-0000000000e1';
|
|
10
|
+
export const F114_DELIVERY_ID = '11400000-0000-4000-8000-0000000000b1';
|
|
11
|
+
export const F114_CRITERION = 'TARA says a held piece can be made shorter or longer only when a shorter or longer piece exists for the design as it stands.';
|
|
12
|
+
export const F114_CRITERION_KEY = `node:${F114_NODE_ID}`;
|
|
13
|
+
const REVIEWS = [
|
|
14
|
+
{ reviewId: 'r-114-7', completedAt: '2026-10-18T10:00:00.000Z', sha: 'aaaaaaa1', bug: 'b-114-7', title: 'TARA offers "longer" when only a same-length piece exists' },
|
|
15
|
+
{ reviewId: 'r-114-8', completedAt: '2026-10-18T14:00:00.000Z', sha: 'aaaaaaa2', bug: 'b-114-8', title: 'TARA implies "a bit shorter" is possible for a sold-out size' },
|
|
16
|
+
{ reviewId: 'r-114-9', completedAt: '2026-10-18T18:00:00.000Z', sha: 'aaaaaaa3', bug: 'b-114-9', title: 'TARA paraphrases "can be adjusted" with no shorter piece' },
|
|
17
|
+
];
|
|
18
|
+
/** The loop_detected decision the review exit recorded. */
|
|
19
|
+
export function f114LoopDecision(over = {}) {
|
|
20
|
+
return {
|
|
21
|
+
towerDecisionId: F114_LOOP_ID,
|
|
22
|
+
focusId: F114_FOCUS_ID,
|
|
23
|
+
kind: 'loop_detected',
|
|
24
|
+
decidedByKind: 'daemon',
|
|
25
|
+
agentSessionId: null,
|
|
26
|
+
summary: `Held the review loop on criterion "${F114_CRITERION}"`,
|
|
27
|
+
rationale: 'The criterion was the only one not_met on 3 consecutive reviews; each named a new blocking finding.',
|
|
28
|
+
evidence: {
|
|
29
|
+
criterionKey: F114_CRITERION_KEY,
|
|
30
|
+
criterion: F114_CRITERION,
|
|
31
|
+
nodeId: F114_NODE_ID,
|
|
32
|
+
threshold: 3,
|
|
33
|
+
reviewCycleCount: 7,
|
|
34
|
+
cap: 8,
|
|
35
|
+
// Newest first, as the detector records them: the history must order them.
|
|
36
|
+
reviews: [...REVIEWS].reverse().map((r) => ({
|
|
37
|
+
reviewId: r.reviewId, completedAt: r.completedAt, blockingIssueIds: [r.bug], newBlockingIssueIds: [r.bug],
|
|
38
|
+
})),
|
|
39
|
+
},
|
|
40
|
+
criterionKey: F114_CRITERION_KEY,
|
|
41
|
+
nodeId: F114_NODE_ID,
|
|
42
|
+
escalationId: null,
|
|
43
|
+
resolvesDecisionId: null,
|
|
44
|
+
createdAt: '2026-10-18T18:01:00.000Z',
|
|
45
|
+
...over,
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
/** The three reviews as the verdict read answers them (newest first). */
|
|
49
|
+
export function f114Reviews() {
|
|
50
|
+
return [...REVIEWS].reverse().map((r) => ({
|
|
51
|
+
reviewId: r.reviewId,
|
|
52
|
+
completedAt: r.completedAt,
|
|
53
|
+
outcome: 'gaps_found',
|
|
54
|
+
criterionVerdicts: [
|
|
55
|
+
{ criterionKey: F114_CRITERION_KEY, nodeId: F114_NODE_ID, source: 'tree', criterion: F114_CRITERION, verdict: 'not_met', issueIds: [r.bug] },
|
|
56
|
+
{ criterionKey: 'text:the fit guide renders', nodeId: null, source: 'focus', criterion: 'The fit guide renders', verdict: 'met', issueIds: [] },
|
|
57
|
+
],
|
|
58
|
+
blockingIssueIds: [r.bug],
|
|
59
|
+
createdIssueIds: [r.bug],
|
|
60
|
+
reviewedSha: r.sha,
|
|
61
|
+
summary: `## Verdicts\n- not_met: ${r.title} (src/tara/length-claims.test.ts misses it)`,
|
|
62
|
+
}));
|
|
63
|
+
}
|
|
64
|
+
/** The blocking Bugs the reviews filed. */
|
|
65
|
+
export function f114Issues() {
|
|
66
|
+
return REVIEWS.map((r, i) => ({
|
|
67
|
+
id: r.bug,
|
|
68
|
+
key: `TT-${900 + i}`,
|
|
69
|
+
title: r.title,
|
|
70
|
+
description: `Seen in a battery transcript. The length check in src/tara/length-claims.test.ts does not cover this phrasing.`,
|
|
71
|
+
status: 'To Do',
|
|
72
|
+
issueType: 'Bug',
|
|
73
|
+
priority: 'high',
|
|
74
|
+
deliveryId: F114_DELIVERY_ID,
|
|
75
|
+
parentIssueId: null,
|
|
76
|
+
context: null,
|
|
77
|
+
relevantFiles: 'src/tara/length-claims.ts, src/tara/length-claims.test.ts',
|
|
78
|
+
dependsOn: null,
|
|
79
|
+
createdByRoleId: null,
|
|
80
|
+
createdAt: r.completedAt,
|
|
81
|
+
}));
|
|
82
|
+
}
|
|
83
|
+
//# sourceMappingURL=tower-loop.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tower-loop.js","sourceRoot":"","sources":["../../../src/testing/fixtures/tower-loop.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,yEAAyE;AACzE,+DAA+D;AAC/D,+DAA+D;AAC/D,gBAAgB;AAkBhB,MAAM,CAAC,MAAM,aAAa,GAAG,sCAAsC,CAAC;AACpE,MAAM,CAAC,MAAM,eAAe,GAAG,sCAAsC,CAAC;AACtE,MAAM,CAAC,MAAM,YAAY,GAAG,sCAAsC,CAAC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,UAAU,UAAU;IACxB,OAAO,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;QAC5B,EAAE,EAAE,CAAC,CAAC,GAAG;QACT,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC,EAAE;QACpB,KAAK,EAAE,CAAC,CAAC,KAAK;QACd,WAAW,EAAE,gHAAgH;QAC7H,MAAM,EAAE,OAAO;QACf,SAAS,EAAE,KAAK;QAChB,QAAQ,EAAE,MAAM;QAChB,UAAU,EAAE,gBAAgB;QAC5B,aAAa,EAAE,IAAI;QACnB,OAAO,EAAE,IAAI;QACb,aAAa,EAAE,2DAA2D;QAC1E,SAAS,EAAE,IAAI;QACf,eAAe,EAAE,IAAI;QACrB,SAAS,EAAE,CAAC,CAAC,WAAW;KACzB,CAAC,CAAC,CAAC;AACN,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What the Tower supervisor is shown about a team escalation's focus: the
|
|
3
|
+
* assembled focus context (the focus, the criteria its arm stamped and where
|
|
4
|
+
* they stand), its deliveries labelled by whether the arm covers them, and the
|
|
5
|
+
* product's standing decisions (read from the product repo by the same
|
|
6
|
+
* convention the review-loop supervisor uses, tower-supervisor-history.ts
|
|
7
|
+
* readStandingDecisions). A failed read never fails the gathering: it is named
|
|
8
|
+
* in readErrors, which the prompt shows.
|
|
9
|
+
*
|
|
10
|
+
* @module tower/tower-escalation-gather
|
|
11
|
+
*/
|
|
12
|
+
import type { DaemonConfig, FocusDeliveryInfo } from '../types/index.js';
|
|
13
|
+
import { type LoopHistoryDeps } from './tower-supervisor-history.js';
|
|
14
|
+
import type { EscalationContext, EscalationFocusDelivery } from './tower-escalation-prompt.js';
|
|
15
|
+
import type { TowerEscalationFocus } from './tower-escalation-session.js';
|
|
16
|
+
/** The context ladder an escalation supervisor reads: the focus, and its arm's stamped criteria and where they stand. */
|
|
17
|
+
export declare const TOWER_ESCALATION_CONTEXT_RECIPE: readonly string[];
|
|
18
|
+
/** The reads the gathering makes. Bound at the composition root. */
|
|
19
|
+
export interface EscalationGatherDeps {
|
|
20
|
+
getFocusDeliveries: (focusId: string) => Promise<FocusDeliveryInfo[]>;
|
|
21
|
+
assembleFocusContext: (focusId: string, productId: string, config: DaemonConfig) => Promise<string>;
|
|
22
|
+
readTextFile: LoopHistoryDeps['readTextFile'];
|
|
23
|
+
listDirectory: LoopHistoryDeps['listDirectory'];
|
|
24
|
+
}
|
|
25
|
+
/** Pure: a delivery labelled by the arm's baseline (null when the arm records none). */
|
|
26
|
+
export declare function labelDelivery(d: FocusDeliveryInfo, baseline: readonly string[] | null): EscalationFocusDelivery;
|
|
27
|
+
/** Gather everything the escalation supervisor is shown. Never throws. */
|
|
28
|
+
export declare function gatherEscalationContext(deps: EscalationGatherDeps, args: {
|
|
29
|
+
focus: TowerEscalationFocus;
|
|
30
|
+
config: DaemonConfig;
|
|
31
|
+
repoRoot: string;
|
|
32
|
+
}): Promise<EscalationContext>;
|
|
33
|
+
//# sourceMappingURL=tower-escalation-gather.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tower-escalation-gather.d.ts","sourceRoot":"","sources":["../../src/tower/tower-escalation-gather.ts"],"names":[],"mappings":"AAIA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACzE,OAAO,EAAyB,KAAK,eAAe,EAA0B,MAAM,+BAA+B,CAAC;AACpH,OAAO,KAAK,EAAE,iBAAiB,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAC/F,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAE1E,yHAAyH;AACzH,eAAO,MAAM,+BAA+B,EAAE,SAAS,MAAM,EAAiD,CAAC;AAE/G,oEAAoE;AACpE,MAAM,WAAW,oBAAoB;IACnC,kBAAkB,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,OAAO,CAAC,iBAAiB,EAAE,CAAC,CAAC;IACtE,oBAAoB,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;IACpG,YAAY,EAAE,eAAe,CAAC,cAAc,CAAC,CAAC;IAC9C,aAAa,EAAE,eAAe,CAAC,eAAe,CAAC,CAAC;CACjD;AAED,wFAAwF;AACxF,wBAAgB,aAAa,CAAC,CAAC,EAAE,iBAAiB,EAAE,QAAQ,EAAE,SAAS,MAAM,EAAE,GAAG,IAAI,GAAG,uBAAuB,CAO/G;AAED,0EAA0E;AAC1E,wBAAsB,uBAAuB,CAC3C,IAAI,EAAE,oBAAoB,EAC1B,IAAI,EAAE;IAAE,KAAK,EAAE,oBAAoB,CAAC;IAAC,MAAM,EAAE,YAAY,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GAC5E,OAAO,CAAC,iBAAiB,CAAC,CAmB5B"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
// PINNED-BY-BEGIN (generated by gen:pinned-by -- do not hand-edit; checked by lint:pinned-by)
|
|
2
|
+
// Pinned by: packages/daemon/src/tower/tower-escalation-prompt.test.ts
|
|
3
|
+
// PINNED-BY-END
|
|
4
|
+
import { readStandingDecisions } from './tower-supervisor-history.js';
|
|
5
|
+
/** The context ladder an escalation supervisor reads: the focus, and its arm's stamped criteria and where they stand. */
|
|
6
|
+
export const TOWER_ESCALATION_CONTEXT_RECIPE = ['focus.context', 'focus.criteria_standing'];
|
|
7
|
+
/** Pure: a delivery labelled by the arm's baseline (null when the arm records none). */
|
|
8
|
+
export function labelDelivery(d, baseline) {
|
|
9
|
+
return {
|
|
10
|
+
deliveryId: d.id,
|
|
11
|
+
name: d.name,
|
|
12
|
+
executionStatus: d.executionStatus ?? 'unknown',
|
|
13
|
+
covered: baseline === null ? null : baseline.includes(d.id),
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/** Gather everything the escalation supervisor is shown. Never throws. */
|
|
17
|
+
export async function gatherEscalationContext(deps, args) {
|
|
18
|
+
const { focus, config, repoRoot } = args;
|
|
19
|
+
const readErrors = [];
|
|
20
|
+
const [deliveries, focusContext] = await Promise.all([
|
|
21
|
+
deps.getFocusDeliveries(focus.focusId).catch((err) => { readErrors.push(`focus deliveries: ${err.message}`); return []; }),
|
|
22
|
+
deps.assembleFocusContext(focus.focusId, focus.productId, config).catch((err) => { readErrors.push(`focus context: ${err.message}`); return ''; }),
|
|
23
|
+
]);
|
|
24
|
+
let standingDecisions = { source: null, text: '', truncated: false };
|
|
25
|
+
try {
|
|
26
|
+
standingDecisions = readStandingDecisions(repoRoot, deps);
|
|
27
|
+
}
|
|
28
|
+
catch (err) {
|
|
29
|
+
readErrors.push(`standing decisions: ${err.message}`);
|
|
30
|
+
}
|
|
31
|
+
return {
|
|
32
|
+
focusContext,
|
|
33
|
+
deliveries: deliveries.map((d) => labelDelivery(d, focus.armedBaselineDeliveryIds)),
|
|
34
|
+
standingDecisions,
|
|
35
|
+
readErrors,
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=tower-escalation-gather.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tower-escalation-gather.js","sourceRoot":"","sources":["../../src/tower/tower-escalation-gather.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,uEAAuE;AACvE,gBAAgB;AAehB,OAAO,EAAE,qBAAqB,EAAgD,MAAM,+BAA+B,CAAC;AAIpH,yHAAyH;AACzH,MAAM,CAAC,MAAM,+BAA+B,GAAsB,CAAC,eAAe,EAAE,yBAAyB,CAAC,CAAC;AAU/G,wFAAwF;AACxF,MAAM,UAAU,aAAa,CAAC,CAAoB,EAAE,QAAkC;IACpF,OAAO;QACL,UAAU,EAAE,CAAC,CAAC,EAAE;QAChB,IAAI,EAAE,CAAC,CAAC,IAAI;QACZ,e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a,CAAC,OAAO,EAAE,CAAC,CAAC;IACnE,CAAC;IACD,OAAO;QACL,YAAY;QACZ,UAAU,EAAE,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,EAAE,KAAK,CAAC,wBAAwB,CAAC,CAAC;QACnF,iBAAiB;QACjB,UAAU;KACX,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Tower supervisor's ESCALATION prompt: a pure builder over one team
|
|
3
|
+
* escalation pending on it and what the daemon gathered about its focus.
|
|
4
|
+
*
|
|
5
|
+
* The operator ruled the scope: the supervisor decides what lies within the
|
|
6
|
+
* scope the team is solving for -- usually by authorizing the team's own
|
|
7
|
+
* recommendation -- WITHOUT the operator, and every decision is recorded on the
|
|
8
|
+
* focus. It defers to the operator a major new build, and anything it feels
|
|
9
|
+
* needs a human. (An escalation naming a human-only act never reaches it: the
|
|
10
|
+
* daemon hands those straight on, tower/tower-escalation-routing.ts.)
|
|
11
|
+
*
|
|
12
|
+
* What it is shown: the escalation (description, what was tried, the help
|
|
13
|
+
* asked for -- where the team's recommendation is), the focus and its assembled
|
|
14
|
+
* context, the ARM (the criteria it stamped and where they stand; the
|
|
15
|
+
* deliveries it covers and those recorded as new intent after it) and the
|
|
16
|
+
* product's standing decisions.
|
|
17
|
+
*
|
|
18
|
+
* What it is never given: a budget lever. The prompt carries no review-cycle
|
|
19
|
+
* count, no cap and no arm act, and says outright that none exist for it; the
|
|
20
|
+
* bound is the scoped `tower_supervisor` MCP profile, under which no tool can
|
|
21
|
+
* arm, unarm or grant review cycles (mcp/telora-products src/profile-scope.ts).
|
|
22
|
+
*
|
|
23
|
+
* @module tower/tower-escalation-prompt
|
|
24
|
+
*/
|
|
25
|
+
import type { StandingDecisions } from './tower-supervisor-history.js';
|
|
26
|
+
import type { TowerPendingEscalation } from '../queries/escalations/tower-escalations.js';
|
|
27
|
+
/** The last line the session prints (informational; the record decides). */
|
|
28
|
+
export declare const TOWER_ESCALATION_LINE_PREFIX = "TOWER DECISION:";
|
|
29
|
+
/** One delivery of the focus, and whether the arm covers it. */
|
|
30
|
+
export interface EscalationFocusDelivery {
|
|
31
|
+
deliveryId: string;
|
|
32
|
+
name: string;
|
|
33
|
+
executionStatus: string;
|
|
34
|
+
/** true = in the arm's baseline; false = recorded as new intent after it; null = the arm records no baseline. */
|
|
35
|
+
covered: boolean | null;
|
|
36
|
+
}
|
|
37
|
+
/** What the daemon gathered for one escalation. */
|
|
38
|
+
export interface EscalationContext {
|
|
39
|
+
/** The assembled focus context ladder (the focus, its stamped criteria and where they stand). */
|
|
40
|
+
focusContext: string;
|
|
41
|
+
deliveries: EscalationFocusDelivery[];
|
|
42
|
+
standingDecisions: StandingDecisions;
|
|
43
|
+
readErrors: string[];
|
|
44
|
+
}
|
|
45
|
+
/** Inputs of one escalation prompt. */
|
|
46
|
+
export interface TowerEscalationPromptInput {
|
|
47
|
+
focus: {
|
|
48
|
+
focusId: string;
|
|
49
|
+
focusName: string;
|
|
50
|
+
focusDescription: string | null;
|
|
51
|
+
productId: string;
|
|
52
|
+
};
|
|
53
|
+
escalation: TowerPendingEscalation;
|
|
54
|
+
/** The id this session acts under: every act it takes carries it as agentSessionId. */
|
|
55
|
+
supervisorSessionId: string;
|
|
56
|
+
context: EscalationContext;
|
|
57
|
+
}
|
|
58
|
+
/** Pure: the whole escalation prompt. */
|
|
59
|
+
export declare function buildTowerEscalationPrompt(input: TowerEscalationPromptInput): string;
|
|
60
|
+
/** Pure: the decision the session's last line states, or null. Informational: the record decides. */
|
|
61
|
+
export declare function parseTowerEscalationLine(stdout: string): 'answered' | 'deferred' | null;
|
|
62
|
+
//# sourceMappingURL=tower-escalation-prompt.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tower-escalation-prompt.d.ts","sourceRoot":"","sources":["../../src/tower/tower-escalation-prompt.ts"],"names":[],"mappings":"AAIA;;;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: packages/daemon/src/tower/tower-escalation-prompt.test.ts
|
|
3
|
+
// PINNED-BY-END
|
|
4
|
+
/** The last line the session prints (informational; the record decides). */
|
|
5
|
+
export const TOWER_ESCALATION_LINE_PREFIX = 'TOWER DECISION:';
|
|
6
|
+
function fence(text) {
|
|
7
|
+
return ['```', text.replace(/```/g, "'''"), '```'].join('\n');
|
|
8
|
+
}
|
|
9
|
+
function escalationSection(input) {
|
|
10
|
+
const e = input.escalation;
|
|
11
|
+
const out = [
|
|
12
|
+
'## The escalation',
|
|
13
|
+
'',
|
|
14
|
+
`escalationId ${e.escalationId}, filed ${e.createdAt} by a team on this focus` +
|
|
15
|
+
`${e.deliveryId ? ` (deliveryId ${e.deliveryId})` : ''}${e.issueId ? ` (issueId ${e.issueId})` : ''}.`,
|
|
16
|
+
`Reason: ${e.reasonType}; disposition: ${e.disposition ?? 'unset'}.`,
|
|
17
|
+
'',
|
|
18
|
+
'What happened and why the team escalated:',
|
|
19
|
+
fence(e.description.trim() === '' ? '(no description)' : e.description),
|
|
20
|
+
];
|
|
21
|
+
if (e.whatWasTried)
|
|
22
|
+
out.push('', 'What the team tried:', fence(e.whatWasTried));
|
|
23
|
+
if (e.helpNeeded)
|
|
24
|
+
out.push('', 'What the team asks for (its recommendation, when it made one, is usually here):', fence(e.helpNeeded));
|
|
25
|
+
out.push('');
|
|
26
|
+
return out;
|
|
27
|
+
}
|
|
28
|
+
function deliveryLine(d) {
|
|
29
|
+
const arm = d.covered === null ? '' : d.covered ? ', covered by the arm' : ', recorded as new intent after the arm (not covered)';
|
|
30
|
+
return `- "${d.name}" (deliveryId ${d.deliveryId}, ${d.executionStatus}${arm})`;
|
|
31
|
+
}
|
|
32
|
+
function contextSection(ctx) {
|
|
33
|
+
const out = ['## The focus, and the arm (the criteria it stamped and where they stand)', ''];
|
|
34
|
+
out.push(ctx.focusContext.trim() === '' ? '(The focus context could not be assembled.)' : ctx.focusContext.trim(), '');
|
|
35
|
+
out.push('### Deliveries', '');
|
|
36
|
+
if (ctx.deliveries.length === 0)
|
|
37
|
+
out.push('(none readable)');
|
|
38
|
+
for (const d of ctx.deliveries)
|
|
39
|
+
out.push(deliveryLine(d));
|
|
40
|
+
out.push('', '## The product\'s standing decisions', '');
|
|
41
|
+
const sd = ctx.standingDecisions;
|
|
42
|
+
if (sd.source === null)
|
|
43
|
+
out.push('This product keeps no decisions log the daemon could find. Decide from the focus alone.');
|
|
44
|
+
else {
|
|
45
|
+
out.push(`From ${sd.source}${sd.truncated ? ' (newest entries; cut at the size cap -- read the file for older ones)' : ''}. What is ruled here is not re-decided.`, '', sd.text);
|
|
46
|
+
}
|
|
47
|
+
out.push('');
|
|
48
|
+
if (ctx.readErrors.length > 0)
|
|
49
|
+
out.push('## What you were NOT given (a read failed)', '', ...ctx.readErrors.map((e) => `- ${e}`), '');
|
|
50
|
+
return out;
|
|
51
|
+
}
|
|
52
|
+
function instructionsSection(input) {
|
|
53
|
+
const { escalation: e, supervisorSessionId: sid } = input;
|
|
54
|
+
const ids = `escalationId "${e.escalationId}", agentSessionId "${sid}"`;
|
|
55
|
+
return [
|
|
56
|
+
'## What you do, in order',
|
|
57
|
+
'',
|
|
58
|
+
'1. **Read the ask.** What does the team need decided, and what does it recommend? Read the code it names in',
|
|
59
|
+
' this worktree if that is how you judge it (read only).',
|
|
60
|
+
'2. **Judge it against the scope the team is solving for**: the focus\'s intent, the criteria its arm stamped, the',
|
|
61
|
+
' deliveries the arm covers, and the standing decisions above. A path is within scope when it serves that intent',
|
|
62
|
+
' inside those criteria and decisions -- most escalations are: a fork the team could act on but would not decide',
|
|
63
|
+
' alone. Prefer the team\'s own recommendation when it is within scope; when two paths are, prefer the one that',
|
|
64
|
+
' is reversible.',
|
|
65
|
+
'3. **When you can recommend a path within that scope, ANSWER it** with `telora_agent` action "escalation_answer":',
|
|
66
|
+
` ${ids}, answer (addressed to the team, imperative: what to do, and any condition), summary (WHAT you`,
|
|
67
|
+
' decided), rationale (WHY it is within scope), decisionEvidence { recommendation: "team" | "supervisor",',
|
|
68
|
+
' criteria: [the criteria it rests on], standingDecisions: [the entries it cites], alternatives: [what you',
|
|
69
|
+
' rejected and why] }. That one call resolves the escalation, records escalation_answered on the focus, and',
|
|
70
|
+
' the daemon hands your answer to the team (its live session now, or its next spawn).',
|
|
71
|
+
'4. **DEFER it to the operator** with `telora_agent` action "escalation_defer" (' + ids + ', summary,',
|
|
72
|
+
' rationale) -- the escalation then stands in the operator\'s inbox -- when any of these holds:',
|
|
73
|
+
' - it asks for a MAJOR NEW BUILD: a new capability, product surface or focus beyond what the arm covers;',
|
|
74
|
+
' - the intent is genuinely open: the focus and the standing decisions leave two readings that change the',
|
|
75
|
+
' outcome, and neither is clearly the team\'s scope;',
|
|
76
|
+
' - it needs a human act after all (something irreversible, outward, or a credential no agent reaches);',
|
|
77
|
+
' - you feel a human is needed. When in doubt between answering and deferring, DEFER.',
|
|
78
|
+
'',
|
|
79
|
+
];
|
|
80
|
+
}
|
|
81
|
+
function boundariesSection() {
|
|
82
|
+
return [
|
|
83
|
+
'## What you never do',
|
|
84
|
+
'',
|
|
85
|
+
'- You hold NO budget lever. You cannot grant review cycles, extend a budget, re-arm, un-arm or stop the',
|
|
86
|
+
' focus; your Telora tools do not offer it. An answer never widens the arm: new intent is the operator\'s.',
|
|
87
|
+
'- You do not amend a criterion, write code, commit, or file a new escalation for this one: answering or',
|
|
88
|
+
' deferring THIS escalation is the whole act.',
|
|
89
|
+
'- You do not lower the bar to unblock the team: an answer that drops a stamped criterion is a deferral.',
|
|
90
|
+
'- You decide exactly once: one escalation_answer OR one escalation_defer.',
|
|
91
|
+
'',
|
|
92
|
+
`End with one line: \`${TOWER_ESCALATION_LINE_PREFIX} answered\` or \`${TOWER_ESCALATION_LINE_PREFIX} deferred\`.`,
|
|
93
|
+
];
|
|
94
|
+
}
|
|
95
|
+
/** Pure: the whole escalation prompt. */
|
|
96
|
+
export function buildTowerEscalationPrompt(input) {
|
|
97
|
+
const { focus } = input;
|
|
98
|
+
return [
|
|
99
|
+
`# Tower supervisor: answer a team escalation on "${focus.focusName}"`,
|
|
100
|
+
'',
|
|
101
|
+
'You are the Tower supervisor. A team working this armed focus escalated a question. The operator ruled that',
|
|
102
|
+
'you answer what lies within the scope the team is solving for -- usually by authorizing the team\'s own',
|
|
103
|
+
'recommendation -- WITHOUT the operator, and that every decision you make is recorded on the focus (what, why,',
|
|
104
|
+
'and the evidence), where the dashboard shows it. Only what you cannot answer, or a major new build, goes to',
|
|
105
|
+
'the operator.',
|
|
106
|
+
'',
|
|
107
|
+
`Focus: "${focus.focusName}" (focusId ${focus.focusId}, productId ${focus.productId})`,
|
|
108
|
+
...(focus.focusDescription ? ['', fence(focus.focusDescription)] : []),
|
|
109
|
+
'',
|
|
110
|
+
...escalationSection(input),
|
|
111
|
+
...contextSection(input.context),
|
|
112
|
+
...instructionsSection(input),
|
|
113
|
+
...boundariesSection(),
|
|
114
|
+
].join('\n');
|
|
115
|
+
}
|
|
116
|
+
/** Pure: the decision the session's last line states, or null. Informational: the record decides. */
|
|
117
|
+
export function parseTowerEscalationLine(stdout) {
|
|
118
|
+
for (const line of stdout.trim().split('\n').reverse()) {
|
|
119
|
+
const at = line.indexOf(TOWER_ESCALATION_LINE_PREFIX);
|
|
120
|
+
if (at === -1)
|
|
121
|
+
continue;
|
|
122
|
+
const word = line.slice(at + TOWER_ESCALATION_LINE_PREFIX.length).trim().replace(/[`*.]/g, '').toLowerCase();
|
|
123
|
+
if (word.startsWith('answered'))
|
|
124
|
+
return 'answered';
|
|
125
|
+
if (word.startsWith('deferred'))
|
|
126
|
+
return 'deferred';
|
|
127
|
+
}
|
|
128
|
+
return null;
|
|
129
|
+
}
|
|
130
|
+
//# sourceMappingURL=tower-escalation-prompt.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tower-escalation-prompt.js","sourceRoot":"","sources":["../../src/tower/tower-escalation-prompt.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,uEAAuE;AACvE,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