Guides

Limits and Quotas

Configurable limits for Agent OS — per-agent limits, timeouts, and context.

Overview

Agent OS supports per-agent limits and server behaviour so you can cap runtime, tokens, and turns. This page summarizes the main limits; exact env or config keys may vary by build—check the runtime and config code.

Per-agent limits

When creating or updating an agent, you can set limits in the agent config (e.g. via API or dashboard):

LimitDescription
max_turnsMaximum tool-call turns per run. After this, the run stops even if the model would continue.
max_tokensApproximate token cap for the model response (or total context).
max_runtimeMaximum duration (e.g. in seconds or ms) for a single run.

The runtime enforces these so a single agent run cannot run indefinitely or consume unbounded context.

Server and run behaviour

  • Idle timeout — The HTTP server may set an idle timeout (e.g. 120 seconds) so long-running agent runs (LLM + tool calls) are not cut off too early. Configurable in the server options if exposed.
  • Conversation history — When passing conversation_id to POST /api/agents/run or run/stream, the runtime may truncate or summarize old messages to stay within a context window. Limits (e.g. max history messages or max context tokens) may be configurable via env or runtime options.

Skills and tools

  • Allowed tools — Each agent declares skills (and optionally an explicit tools list). Only tools from those skills and the built-in allowlist are exposed to the model. This effectively limits what the agent can call.
  • Workspace — File-access tools are restricted to the agent’s workspace directory (~/.agent-os/workspaces/{agent_id}/). No access outside that sandbox.

Rate limiting

Agent OS does not document a built-in global rate limit (e.g. per-IP). If you need rate limiting, put the server behind a reverse proxy (e.g. nginx, Caddy) and configure limits there, or add rate limiting in the server code and document the env vars (e.g. RATE_LIMIT_MAX, RATE_LIMIT_WINDOW_MS).

For the latest limits and env vars, see the runtime and config code in the repo (e.g. src/core/runtime.ts, src/core/config.ts, agent limits in types/agent.ts).