# Limits

The numbers a caller meets, in one place. Each tool's own page lists its timeout and argument
limits too.

**In short:** 8 calls at once per machine (`busy` beyond), 16 MiB per call's arguments or result (`too_large`),
`exec_run` up to 600 s, 120 screen input actions a minute (`rate_limited`).

## Calls

| Limit | Value | Beyond it |
|---|---|---|
| Calls running at once on one machine | 8 | [`busy`](https://docs.cmdop.ai/reference/errors/busy.md): wait and retry |
| A call's arguments or its result | 16 MiB | [`too_large`](https://docs.cmdop.ai/reference/errors/too_large.md): nothing is sent, the machine stays online |
| Time per call | per tool, 10 s to 620 s; on each [tool's page](https://docs.cmdop.ai/reference/tools.md) | [`timed_out`](https://docs.cmdop.ai/reference/errors/timed_out.md) |

## Commands and tasks

| Limit | Value |
|---|---|
| `exec_run` timeout | 120 s by default, at most 600 s; then the process group is stopped |
| `exec_run` output kept in the answer | the last 64 KiB of each stream; the rest goes to `stdout_file` / `stderr_file` |
| Task terminal | 120 × 40 by default |
| Task output kept | 1000 lines of each of the last 50 tasks, until the machine program restarts |
| `task_output` | the last 200 lines by default |
| `task_stop` | SIGTERM, then SIGKILL after 5 s |

## Files

| Limit | Value |
|---|---|
| `fs_read` per call | 256 KiB by default, at most 4 MiB; read on with `offset` |
| `fs_write` | 8 MiB |
| `fs_edit` | text files up to 4 MiB |
| `fs_stat` with `hash` | files up to 64 MiB |
| `fs_list` | 500 entries by default, at most 5000 |
| `fs_search` | 200 matches by default, at most 2000; 12 folder levels by default, at most 64; `content` skips files over 4 MiB |

## Screen and control

| Limit | Value |
|---|---|
| `screen_capture` image | longest side 1280 px by default, at most 2000 |
| `ui_wait` | at most 30 s |
| Control of the screen | given back after 60 s without an input call |
| Input actions | 120 a minute; beyond: [`rate_limited`](https://docs.cmdop.ai/reference/errors/rate_limited.md) |

## Records

| Record | Kept |
|---|---|
| The machine's own record of calls and tasks (`journal_search`) | 30 days or 500 MiB, whichever comes first |
| `journal_search` answers | 100 entries by default, at most 500 |
| `history_search` answers | 50 of each kind by default, at most 200 |
| Screen and control actions on the machine (`cmdop control audit.tail`) | 7 days or 200 MiB |
