Skip to content

Hold agent messages to a usage-limited agent until it continues #718

Closed

Description

@Jacksondr5

Problem

When an agent has stopped on its provider's usage limit, upstream usually leaves its queue unheld. A J5 delivery to it is still handed over:

  • Nothing is queued: the delivery starts a turn at once, as upstream does for any message to an idle thread. The provider is still limited, so the turn fails immediately. The sender isn't told. Whether the agent ever acts on the message depends on whether the provider kept it in its session history before upstream's "Continue where you left off." runs at the reset, and on auto-continue being on.
  • Messages are already queued: the delivery joins them and waits silently. Upstream's queue start returns early while the thread is limited (Orchestrator.ts, "The limit already stopped this thread").

A person sees the Limited banner and waits. An agent sender can't see it.

Today J5 holds a delivery unsent only when the receiver is limited and has a held queue (idleQueueHold in DeliveryTransport.ts, since #710). Found by the #272 builder.

Fix (Jackson, 2026-10-24)

Hold every J5 delivery to a usage-limited agent unsent until the agent continues, whether or not its queue is held. Then deliver in send order. #710's usage-limit notices ("…continues automatically at…" / "…paused until a person continues it") then cover this case. Rewrite D4 in docs/j5/product/upstream.md to match.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions