Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Usage and limits

Agents use tokens, and their accounts have limits. Cuewire shows how much your agents use, holds tasks when an agent reaches its limit, and can run agents on other accounts. This page explains how.

Figure: The usage panel. Click the chip at the bottom left to open it.

The usage chip

The usage chip sits at the bottom left of the canvas. It shows the tokens your agents used in the last 24 hours, for example Usage 1.2M tokens · 24 h.

Click it to open the usage panel. Or press Ctrl+K (Cmd+K on a Mac) and run Show usage.

Cuewire reads these numbers from the agents’ own logs on this computer: Claude Code, Codex, Copilot CLI and Gemini CLI. It reads them again every half minute. Nothing leaves your computer.

The panel has these parts:

PartWhat it shows
TokensTokens used in the last 5 hours, 24 hours and 7 days.
LimitsEach account’s usage windows: how much is used, and when it resets.
This canvasTokens, and cost where known, for each agent on this canvas.
Held tasksTasks waiting for an agent’s limit to clear.
Models, Accounts, ProjectsWhere the last 24 hours of tokens went.
At once (concurrency caps)How many agents of each kind may run at once.

Note

Claude Code’s logs don’t report its 5-hour window, so Cuewire estimates it. Live totals can be a few percent lower than your bill.

When an agent reaches its limit

Cuewire notices when an agent can’t take more work:

  • the agent shows its own usage-limit message, for example that a limit was reached and when it resets; or
  • a Codex agent’s account has used 95% or more of its current window.

Then new tasks for that agent are held. A held task is not lost:

  • The agent’s header shows 1 task held (or more).
  • The usage panel lists it under Held tasks (they go out when the limit clears), with the reason and who sent it.
  • The sender’s cuewire ask or cuewire send says why the task waits.

The task goes out by itself when the limit clears. Two things can get it moving sooner:

  • A key pool: Cuewire moves the agent to its next key. See Key pools below.
  • --reroute: if the sender allowed it, an idle agent with the same role takes the task. Cuewire tries an agent of the same kind first. The sender is told who took it.

Figure: Three ways a held task gets done.

Figure: The header shows how many tasks wait for this agent.

Concurrency caps

A concurrency cap limits how many agents of one kind run at once. It stops parallel agents from using up an account’s limit together.

  1. Open the usage panel.
  2. Under At once (concurrency caps), find the agent. It shows no cap at first.
  3. Click − to set a cap. Each click lowers it, from 8 down to 1. Click + to raise it. Above 8, it goes back to no cap.

An agent over the cap waits on its node, for example “Waiting: 2 Claude Code agents are already running (the cap; change it under Usage)”. It starts when another agent of its kind stops, or when you raise the cap.

Figure: This agent starts when a slot frees up.

Agent accounts

An agent signs in with this computer’s own login, shown as This computer’s sign-in. You can give an agent another account: a separate login, a set of API keys, or another service.

Add an account:

  1. Press Ctrl+K and run Agent accounts…. Or right-click an agent and choose Manage accounts….
  2. Click Add account.
  3. Under Agent, choose the agent the account is for.
  4. Under Signs in with, choose a kind:
    • Its own folder: the agent keeps its login and history in a folder of its own.
    • API keys: one or more keys, separated by spaces.
    • Another endpoint: an address (https://…) and its token, for a proxy or a compatible service.
  5. Type a Name, then click Add.

With Its own folder, start an agent on the account and sign in there once.

Figure: The Agent accounts sheet. Keys go into masked fields.

Each agent supports these kinds:

AgentIts own folderAPI keysAnother endpoint
Claude Codeyesyesyes
Codexyesyesyes
Gemini CLIyesyesyes
Antigravityyesyesyes
Copilot CLIyesyes (a GitHub token)–
Grokyesyes–
OpenCodeyes––

Keys and tokens are kept in your system’s keychain (Credential Manager on Windows, Keychain on a Mac), never in a file. When you remove an account, its keys leave the keychain. An account’s own folder stays, with its login and history.

Put an agent on an account:

  1. Right-click the agent.
  2. Under Account, choose the account.
  3. Restart the agent. The account applies when it starts.

Figure: The Account section of an agent’s menu.

Note

A conversation belongs to the account it ran on. When you change an agent’s account, the agent starts a new conversation.

The usage panel shows each own-folder account’s usage under the account’s name, in Accounts, last 24 hours.

Key pools and the next key

An account with more than one API key is a key pool. Each new agent on it takes the next key in turn. An agent keeps its key when it restarts, and when you restart Cuewire.

  • To move an agent to the following key, right-click it and choose Restart with next key (now 1 of 3). The numbers show which key it uses now.
  • Move to the next key when one reaches its limit is on for a new pool. With it on, Cuewire does this for you. When a task is held because the agent is at its limit, Cuewire restarts the agent on the next key. The agent resumes its conversation and takes the task. Each key is tried once, a minute apart.

A message tells you, for example “Worker reached a usage limit; restarted on key 2 of 3”.

What’s next