@markusylisiurunen/tau 0.3.81 → 0.3.83
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/README.md +1 -3
- package/dist/core/agent/agent_runtime.js +6 -4
- package/dist/core/agent/agent_runtime.js.map +1 -1
- package/dist/core/cli.js +2 -2
- package/dist/core/cli.js.map +1 -1
- package/dist/core/code_mode/models.js +61 -22
- package/dist/core/code_mode/models.js.map +1 -1
- package/dist/core/commands/registry.js +0 -22
- package/dist/core/commands/registry.js.map +1 -1
- package/dist/core/history/cli.js +48 -0
- package/dist/core/history/cli.js.map +1 -1
- package/dist/core/history/history_manager.js +9 -3
- package/dist/core/history/history_manager.js.map +1 -1
- package/dist/core/history/local_history_store.js +9 -2
- package/dist/core/history/local_history_store.js.map +1 -1
- package/dist/core/history/remote_history_client.js +18 -3
- package/dist/core/history/remote_history_client.js.map +1 -1
- package/dist/core/models/openrouter.js +17 -5
- package/dist/core/models/openrouter.js.map +1 -1
- package/dist/core/models/openrouter_decisions.js +16 -1
- package/dist/core/models/openrouter_decisions.js.map +1 -1
- package/dist/core/runtime/chat_runtime.js +2 -13
- package/dist/core/runtime/chat_runtime.js.map +1 -1
- package/dist/core/static/tau_docs/client-tools.md +53 -53
- package/dist/core/static/tau_docs/config-reference.md +46 -43
- package/dist/core/static/tau_docs/configuration.md +40 -36
- package/dist/core/static/tau_docs/credentials.md +32 -31
- package/dist/core/static/tau_docs/getting-started.md +28 -28
- package/dist/core/static/tau_docs/history.md +114 -79
- package/dist/core/static/tau_docs/image-generation.md +20 -18
- package/dist/core/static/tau_docs/index.md +30 -31
- package/dist/core/static/tau_docs/manifest.json +1 -0
- package/dist/core/static/tau_docs/models.md +17 -17
- package/dist/core/static/tau_docs/node-sdk.md +69 -72
- package/dist/core/static/tau_docs/nook.md +75 -69
- package/dist/core/static/tau_docs/openrouter.md +28 -13
- package/dist/core/static/tau_docs/ownership-and-scope.md +21 -23
- package/dist/core/static/tau_docs/pdf-unpacking.md +6 -6
- package/dist/core/static/tau_docs/personas.md +29 -27
- package/dist/core/static/tau_docs/prompts-and-project-context.md +41 -39
- package/dist/core/static/tau_docs/remote-sessions.md +38 -38
- package/dist/core/static/tau_docs/sdk-diff-review.md +16 -12
- package/dist/core/static/tau_docs/security.md +72 -72
- package/dist/core/static/tau_docs/session-protocol-methods.md +46 -91
- package/dist/core/static/tau_docs/session-protocol.md +54 -54
- package/dist/core/static/tau_docs/sessions.md +97 -107
- package/dist/core/static/tau_docs/skills.md +25 -20
- package/dist/core/static/tau_docs/speech-generation.md +5 -5
- package/dist/core/static/tau_docs/subagents.md +42 -44
- package/dist/core/static/tau_docs/telegram-projects.md +142 -0
- package/dist/core/static/tau_docs/telegram.md +65 -182
- package/dist/core/static/tau_docs/tools.md +72 -91
- package/dist/core/static/tau_docs/troubleshooting.md +94 -149
- package/dist/core/static/tau_docs/tui.md +124 -81
- package/dist/core/telegram/adapter.js +1 -6
- package/dist/core/telegram/adapter.js.map +1 -1
- package/dist/core/tool/image_generate.js +5 -17
- package/dist/core/tool/image_generate.js.map +1 -1
- package/dist/core/tool/openrouter.js +21 -2
- package/dist/core/tool/openrouter.js.map +1 -1
- package/dist/core/tools/catalog.js +0 -11
- package/dist/core/tools/catalog.js.map +1 -1
- package/dist/core/tools/tool_names.js +0 -6
- package/dist/core/tools/tool_names.js.map +1 -1
- package/dist/core/utils/gemini_transcription.js +103 -28
- package/dist/core/utils/gemini_transcription.js.map +1 -1
- package/dist/core/utils/model_stream.js +17 -1
- package/dist/core/utils/model_stream.js.map +1 -1
- package/dist/core/utils/user_metadata.js +0 -14
- package/dist/core/utils/user_metadata.js.map +1 -1
- package/dist/core/version.js +2 -2
- package/dist/diff_tool/app/dist/assets/{angular-html-BbLgbIhq.js → angular-html-x29PkEoY.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{angular-ts-DXk17TRM.js → angular-ts-CsWCqoCf.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{apl-BsvksCXR.js → apl-CEvdc7jl.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{astro-DH775E4V.js → astro-Cgi6YxH2.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{blade-Ck99Rm59.js → blade-B0pr7Zx6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{c-DJpHqu5J.js → c-DDVLgtVy.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{chapel-Owff0Csy.js → chapel-Bk9M7Jej.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{cobol-Cv2gZuhO.js → cobol-DyEvnPuC.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{coffee-Bji0YCf_.js → coffee-Di2-m3Jq.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{cpp-DTjA_yFF.js → cpp-CWpAaUgO.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{crystal-Dd00NOeb.js → crystal-CUker9Zt.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{css-D44TN1V6.js → css-D4XpBIiJ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{edge-CVmGSi2m.js → edge-CVxhhF7L.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{elixir-B8Mq7no2.js → elixir-B_FS9APl.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{elm-CXS0I3Z2.js → elm-1KyefTkH.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{erb-B9oDKaUo.js → erb-CCgO9dRW.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{git-rebase-DT-YFebH.js → git-rebase-D0VYo_oY.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glimmer-js-s0DXlNjq.js → glimmer-js-Ce07ngjZ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glimmer-ts-QgEB5S2z.js → glimmer-ts-BmOM4djO.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glsl-NA0icwbY.js → glsl-D-jkLYJ8.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{graphql-0_dOlfV0.js → graphql-DZOwJE5e.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{hack-D-mr7l1l.js → hack-Cgvn19h8.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{haml-B0-oQmz7.js → haml-JTmDSYQl.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{handlebars-Yq9bXpWN.js → handlebars-CChh7Dy5.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{html-B8bMmdRK.js → html-BKgzx_cb.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{html-derivative-BpxSlQb_.js → html-derivative-CdFl0BmX.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{http-hS_53mxt.js → http-DZeL7KvH.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{hurl-B2ST1kwl.js → hurl-CqKevOlQ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/index-BXyr8GCM.js +341 -0
- package/dist/diff_tool/app/dist/assets/{java-D4mj0lZJ.js → java-Sq3MCkId.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{javascript-wC7rrKiV.js → javascript-CHZB4Nse.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jinja-DbQ3o87F.js → jinja-C4ucJVla.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jison-CrE9FdvP.js → jison-D3mprebA.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{json-xjicDyWN.js → json-DgPfCYJ1.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jsx-m28lXojQ.js → jsx-BG-Tx0cw.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{julia-19xkOmop.js → julia-B1GnFeUC.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{just-Cf7OorTr.js → just-_MZzo0MF.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{latex-DDb7GQOy.js → latex-DI0kqjQy.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{liquid-DHOuQ0rf.js → liquid-BtMAPeHl.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{lua-BGyIvonw.js → lua-CFxaP0To.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{marko-DB5OqI1C.js → marko-BIJocuFI.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{mdc-DTyNMupO.js → mdc-BAgrdjTH.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{nginx-DfF0fMYD.js → nginx-DE-3CsYn.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{nim-BbwsXuZD.js → nim-DOxeXLhb.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{org-BkOBBl1f.js → org-KTfP0tHA.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{perl-BTXTOl4K.js → perl-BH-NxpgK.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{php-DIMVQWiA.js → php-vuiVEXZK.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{pug-B_nrb4dJ.js → pug-VlIlTMUy.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{qml-1PXi8G8Z.js → qml-k6wTtGG-.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{r-CJrAkc2Z.js → r-Ccjcb2zh.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{razor-DgPUftNd.js → razor-BNhYgSCv.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{regexp-C2hS8XvL.js → regexp-C4LFejPu.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{rst-CDouhKnc.js → rst-DXLxI-UJ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{ruby-CAjKW1uO.js → ruby-BPuL4jDV.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{sas-qAHkHLc1.js → sas-B3Yz8snb.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{scss-Bfx2Ydid.js → scss-B2AJ5vpk.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{shellscript-Bu76R8y2.js → shellscript-zyDexxnC.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{shellsession-BU8BL0oL.js → shellsession-C8b8xluk.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{soy-FRl8ozP-.js → soy-DKWe_XML.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{sql-BacQgsEs.js → sql-uEbz-Epf.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{stata-B9kkG-ET.js → stata-DieRPmHY.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{surrealql-qvETr7iY.js → surrealql-Dbk3Sp1P.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{svelte-B0z1MgHc.js → svelte-CjPbRmkM.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{templ-DTnPshKb.js → templ-Do_f5vc4.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{tex-Cosab9_H.js → tex-UjLP4qUm.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{ts-tags-DNYvLFUH.js → ts-tags-5L2FutA6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{tsx-Dstq6j1a.js → tsx-B1pNtpUr.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{twig-BzqZdwaX.js → twig-O41Vg_IM.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{typescript-YOQ_oE25.js → typescript-Bj9uwnnJ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{typst-DTffwfpc.js → typst-DsibO7oD.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-D4OMj_C5.js → vue-DPhaEurv.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-html-kT4WrHGK.js → vue-html-DDV9NSy1.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-vine-CxeapeMO.js → vue-vine-Dh4jOifx.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{xml-DWVpuurg.js → xml-DtIulkQk.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{xsl-C0ciup5a.js → xsl-DoWtb58Z.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{yaml-98Fvyfpc.js → yaml-CZC-l1Dg.js} +1 -1
- package/dist/diff_tool/app/dist/index.html +1 -1
- package/dist/history/worker/index.js +87 -83
- package/dist/history/worker/index.js.map +1 -1
- package/dist/host/local_session_host.js +24 -318
- package/dist/host/local_session_host.js.map +1 -1
- package/dist/host/session_host.js.map +1 -1
- package/dist/host/session_protocol_handler.js +0 -98
- package/dist/host/session_protocol_handler.js.map +1 -1
- package/dist/main.js +6 -7
- package/dist/main.js.map +1 -1
- package/dist/protocol/index.d.ts +1 -1
- package/dist/protocol/index.js.map +1 -1
- package/dist/protocol/session_protocol.d.ts +3 -28
- package/dist/protocol/session_protocol.js +1 -56
- package/dist/protocol/session_protocol.js.map +1 -1
- package/dist/sdk/index.d.ts +1 -1
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/session.js +0 -20
- package/dist/sdk/session.js.map +1 -1
- package/dist/sdk/types.d.ts +1 -7
- package/dist/store/session_snapshot_migrations.js +72 -1
- package/dist/store/session_snapshot_migrations.js.map +1 -1
- package/dist/tui/session_chat_controller.js +14 -30
- package/dist/tui/session_chat_controller.js.map +1 -1
- package/dist/tui/ui/footer.js +4 -9
- package/dist/tui/ui/footer.js.map +1 -1
- package/package.json +9 -9
- package/dist/core/session/goal.js +0 -54
- package/dist/core/session/goal.js.map +0 -1
- package/dist/core/tools/goal.js +0 -167
- package/dist/core/tools/goal.js.map +0 -1
- package/dist/diff_tool/app/dist/assets/index-CBT_sNIz.js +0 -340
- package/dist/nook/README.md +0 -123
|
@@ -1,25 +1,24 @@
|
|
|
1
1
|
# Tools
|
|
2
2
|
|
|
3
|
-
Tools let an agent act
|
|
3
|
+
Tools let an agent act, not just answer. Tools come from different places: the host provides tools selected by the persona, attached clients can add their own, and a few are always present. Where a tool comes from explains why it is available in one session and missing in another.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
A turn keeps the tool set it started with. Persona changes, reloads, and clients attaching or detaching apply from the next turn.
|
|
6
6
|
|
|
7
7
|
## Tool categories
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
There are three kinds of tools:
|
|
10
10
|
|
|
11
11
|
| Category | Owner and availability |
|
|
12
12
|
| --- | --- |
|
|
13
|
-
| Persona-
|
|
14
|
-
|
|
|
15
|
-
|
|
|
16
|
-
| Client-provided tools | An attached client advertises and executes these. TUI-owned `diff_review` and `prefill_input` are examples. Configured command client tools use the same boundary. |
|
|
13
|
+
| Persona-selected host tools | The host provides them, and they act on the execution environment or host services. The active persona's `tools` list selects them. |
|
|
14
|
+
| Built-in tools | Always present, whatever the persona selects. `tau_docs` is available to main agents and subagents. |
|
|
15
|
+
| Client tools | An attached client offers and runs them. Examples are the TUI's `diff_review` and `prefill_input`, and configured command client tools. |
|
|
17
16
|
|
|
18
|
-
A tool schema tells the model how to call a tool. It
|
|
17
|
+
A tool schema tells the model how to call a tool. It grants no operating-system permissions. Host tools run with the permissions of the execution environment or the host service behind them. Client tools run with the permissions of their client, and can also ask to run commands in the execution environment. See [ownership and scope](ownership-and-scope.md) and [client tools](client-tools.md).
|
|
19
18
|
|
|
20
19
|
## Persona tool selection
|
|
21
20
|
|
|
22
|
-
A custom persona can
|
|
21
|
+
A custom persona can list exactly which tools it uses:
|
|
23
22
|
|
|
24
23
|
```yaml
|
|
25
24
|
tools:
|
|
@@ -30,7 +29,7 @@ tools:
|
|
|
30
29
|
- web
|
|
31
30
|
```
|
|
32
31
|
|
|
33
|
-
The
|
|
32
|
+
The selectable names are:
|
|
34
33
|
|
|
35
34
|
```text
|
|
36
35
|
bash
|
|
@@ -49,97 +48,87 @@ list_agents
|
|
|
49
48
|
interrupt_agent
|
|
50
49
|
```
|
|
51
50
|
|
|
52
|
-
A custom persona that omits `tools`
|
|
51
|
+
A custom persona that omits `tools` gets `bash`, `write`, `edit`, `view_image`, `web`, `nook`, `history`, `mcp`, and `models`, plus the five subagent tools. Built-in personas get the same set.
|
|
53
52
|
|
|
54
|
-
|
|
53
|
+
`web`, `history`, `nook`, `mcp`, and `models` are not separate tools. Each enables a namespace inside the single `code` tool. `bash` enables both the Bash tools and `tau.bash` inside `code`. Tau adds `code` whenever at least one usable capability is selected; `code` itself cannot be listed. A namespace the persona does not select is missing from the `code` API and its documentation.
|
|
55
54
|
|
|
56
|
-
An empty list
|
|
55
|
+
An empty list turns off every selectable tool:
|
|
57
56
|
|
|
58
57
|
```yaml
|
|
59
58
|
tools: []
|
|
60
59
|
```
|
|
61
60
|
|
|
62
|
-
|
|
61
|
+
`tau_docs` stays available. The list also has no effect on client tools, which attached clients offer on their own.
|
|
63
62
|
|
|
64
|
-
|
|
63
|
+
`nook` has one more condition: the host configuration must include a Nook target. Without one, Tau leaves the capability out even if the persona lists it. For other tools, missing credentials or service configuration can make calls fail, but do not remove the tool. Persona configuration is covered in [personas](personas.md).
|
|
65
64
|
|
|
66
|
-
##
|
|
65
|
+
## Tau documentation
|
|
67
66
|
|
|
68
|
-
`tau_docs` reads the
|
|
67
|
+
`tau_docs` reads the documentation shipped with the running Tau version. A persona cannot disable it, and every subagent has it too.
|
|
69
68
|
|
|
70
|
-
The tool
|
|
69
|
+
The tool takes one exact Markdown path, such as `tools.md`. It cannot search or list pages. Start with:
|
|
71
70
|
|
|
72
71
|
```text
|
|
73
72
|
index.md
|
|
74
73
|
```
|
|
75
74
|
|
|
76
|
-
Then follow
|
|
77
|
-
|
|
78
|
-
## Main-session goal tools
|
|
79
|
-
|
|
80
|
-
The main agent always receives:
|
|
81
|
-
|
|
82
|
-
- `get_goal`, which reads the persisted session goal or returns no goal.
|
|
83
|
-
- `create_goal`, which creates an active goal only when the user or an active instruction explicitly requests one.
|
|
84
|
-
- `update_goal`, which changes, completes, or blocks the current goal.
|
|
85
|
-
|
|
86
|
-
These tools are outside persona allowlists because goal lifecycle is a session capability. They are not included in subagent registries or advertised by clients. Goal behavior is described in [sessions](sessions.md).
|
|
75
|
+
Then follow the links on that page. The tool's description also lists the built-in command-line tools, each with a short summary and its page, so agents can open a tool's page directly without reading the index first. Whether those tools work depends on what is installed in the execution environment. Unknown paths are rejected. The documentation describes supported behavior, not a particular session's effective configuration. When the answer depends on local state, inspect the configuration or use debug output.
|
|
87
76
|
|
|
88
77
|
## Execution-environment tools
|
|
89
78
|
|
|
90
79
|
### Bash
|
|
91
80
|
|
|
92
|
-
`bash` runs a command in a fresh non-interactive login Bash in the execution environment. Each call starts a new shell, so shell variables, aliases, functions, `cd`, and other shell state do not carry
|
|
81
|
+
`bash` runs a command in a fresh non-interactive login Bash in the execution environment. Each call starts a new shell, so shell variables, aliases, functions, `cd`, and other shell state do not carry over to the next call. Changes to files and other side effects do persist.
|
|
93
82
|
|
|
94
|
-
Tau starts Bash with `-lc` and the execution environment's `HOME`. A login shell can read `/etc/profile` and then the first available `~/.bash_profile`, `~/.bash_login`, or `~/.profile`. It reads `BASH_ENV` when set. `.bashrc` is otherwise loaded only when a login file sources it.
|
|
83
|
+
Tau starts Bash with `-lc` and the execution environment's `HOME`. A login shell can read `/etc/profile` and then the first available `~/.bash_profile`, `~/.bash_login`, or `~/.profile`. It reads `BASH_ENV` when set. `.bashrc` is otherwise loaded only when a login file sources it. Tau does not suppress anything startup files do, so they must not print output, read stdin, require a terminal, or exit the shell.
|
|
95
84
|
|
|
96
|
-
There is no TTY and
|
|
85
|
+
There is no TTY, and `bash` calls from the agent have no stdin. Commands that prompt, open an editor, or need a terminal hang until the timeout or fail. Use non-interactive flags, and pass `workingDirectory` instead of relying on an earlier `cd`.
|
|
97
86
|
|
|
98
|
-
Tau sets `NO_COLOR=1`, `FORCE_COLOR=0`, `TERM=dumb`, and `PAGER=cat`
|
|
87
|
+
Tau sets `NO_COLOR=1`, `FORCE_COLOR=0`, `TERM=dumb`, and `PAGER=cat` so output is predictable. It also makes Git non-interactive: no terminal or askpass prompts, no editors, no pagers, and SSH in batch mode. These values override inherited ones and anything set by login startup files. A command can still set its own environment variables explicitly. Authentication must therefore work without prompts.
|
|
99
88
|
|
|
100
|
-
Agents are
|
|
89
|
+
Agents are told to choose the mode that avoids needless waiting. Background mode fits when the agent can do other useful work meanwhile, such as reading code while tests run. If the agent would only wait for the result, a foreground call with a suitable `timeout` is better than starting a background job and waiting for it right away. How long a command takes does not decide the mode by itself.
|
|
101
90
|
|
|
102
|
-
Background mode
|
|
91
|
+
Background mode also fits a service that must keep running, or work that must survive turns and interruptions. Starting several independent jobs and then waiting for them is a valid way to run work in parallel. This is guidance for the agent; Tau does not enforce it.
|
|
103
92
|
|
|
104
|
-
The default foreground timeout is 60 seconds. Tau captures at most 1 MiB of
|
|
93
|
+
The default foreground timeout is 60 seconds. Tau captures at most 1 MiB of combined stdout and stderr, and keeps the end when there is more. By default the result the model sees is limited to about 8,192 estimated tokens. Longer output is replaced by a preview of about 2,048 tokens from the middle, with a notice. The command has still run in full, with all its side effects.
|
|
105
94
|
|
|
106
|
-
|
|
95
|
+
A narrower command is better than a higher limit. When more output is really needed, the agent can set `maxOutputTokens` between 8,192 and 16,384 on its own. Values above 16,384, up to 65,536, require an explicit user request. When output is truncated, Tau may save it to a temporary file in the execution environment and report the path.
|
|
107
96
|
|
|
108
|
-
|
|
97
|
+
In a local execution environment, Tau removes inherited environment variables whose names end in `_KEY`, `_SECRET`, `_TOKEN`, or `_PASSWORD`, and `API_KEY`, before running commands. Hosted environments start from their own environment. Variables set explicitly for the environment still apply. Do not print credentials or whole environments.
|
|
109
98
|
|
|
110
|
-
|
|
99
|
+
The TUI commands `!<command>` and `!!<command>` run the same way, in a fresh login shell. `!` adds the result to the model's context and `!!` does not. They allow more output into context than an agent's tool call, but capture is still limited.
|
|
111
100
|
|
|
112
|
-
With `background: true`, `bash` returns a
|
|
101
|
+
With `background: true`, `bash` starts the command and returns a job ID for the session right away, without waiting for it to exit. A started job is not necessarily ready to use. Background jobs have no time limit, and combining `background: true` with `timeout` is invalid. Jobs keep running across turns and interruptions. Main agents, subagents, and ephemeral threads share the session's jobs.
|
|
113
102
|
|
|
114
|
-
Enabling `bash` also enables `list_bash_jobs`, `read_bash_job`, `stop_bash_job`, and `wait_for_bash_jobs`. These
|
|
103
|
+
Enabling `bash` also enables `list_bash_jobs`, `read_bash_job`, `stop_bash_job`, and `wait_for_bash_jobs`. These cannot be listed separately in a persona. List returns short ID and status blocks. Read returns the same blocks with the end of the job's output. Stop terminates the job's process group, and kills it if it has not exited after a grace period. Tau keeps up to 64 job records and drops the oldest finished one when needed. Starting a job fails if all 64 are still running. Each job keeps 64 KiB of combined output. At most 2,048 estimated tokens are returned per job, and 8,192 in total when several jobs are observed at once. Background output ignores `maxOutputTokens` and is never saved to an overflow file.
|
|
115
104
|
|
|
116
|
-
`read_bash_job`, `stop_bash_job`, and `wait_for_bash_jobs` accept `includeOutput`,
|
|
105
|
+
`read_bash_job`, `stop_bash_job`, and `wait_for_bash_jobs` accept `includeOutput`, which defaults to `true`. With `false`, the result leaves out stdout, stderr, and truncation notices, but still has the job ID, command, cwd, status, exit code once finished, termination reason, and errors. List never includes output.
|
|
117
106
|
|
|
118
|
-
|
|
107
|
+
In the TUI, job tool cards have headings such as `reading bash <id>` and `listed bash jobs`, and show a seven-line preview from the middle of the result. A background start shows `started background <command>`, which means only that the command started.
|
|
119
108
|
|
|
120
|
-
|
|
109
|
+
When a job tool call is invalid or fails, the TUI card shows a short diagnostic as well as the model's result. A normal cancellation shows no details.
|
|
121
110
|
|
|
122
|
-
`wait_for_bash_jobs({ids, timeout?, includeOutput?})` returns when any
|
|
111
|
+
`wait_for_bash_jobs({ids, timeout?, includeOutput?})` returns when any of the jobs exits or the wait times out. Jobs that already finished return immediately. The timeout is a positive integer in milliseconds, defaults to 60,000, and can be at most 300,000. A timeout counts as a successful result and does not stop the jobs. Interrupting the wait leaves them running too. The tool waits for a job to exit, not to become ready, so check a server's logs or readiness instead. A job finishing never starts an agent turn by itself.
|
|
123
112
|
|
|
124
|
-
Jobs survive client disconnects while the host
|
|
113
|
+
Jobs survive client disconnects while the host is running, and keep an idle session from being unloaded until they finish. Closing the session normally or shutting down the host stops them. Job IDs and logs are not saved or recovered, and an old ID fails with a clear error. An unknown ID does not mean the command never ran, that its side effects were undone, or that it has stopped. Agents are told to check running processes and output before starting such a command again. Cleanup does not cover processes that daemonize themselves, tmux sessions, or processes left behind by a host crash or forced kill.
|
|
125
114
|
|
|
126
115
|
### Write and edit
|
|
127
116
|
|
|
128
|
-
`write` creates or overwrites a UTF-8 file
|
|
117
|
+
`write` creates or overwrites a UTF-8 file, creating missing parent directories. Relative paths resolve from the session's working directory. It replaces the whole file, so use it for new files or deliberate full rewrites.
|
|
129
118
|
|
|
130
119
|
`edit` performs one exact textual replacement in an existing UTF-8 file. `oldText` must be non-empty and match exactly once, including whitespace and newlines. Zero matches and multiple matches are rejected without changing the file. Read the current section first and make `oldText` more specific when necessary.
|
|
131
120
|
|
|
132
|
-
Neither tool
|
|
121
|
+
Neither tool reads files. To inspect text, use a focused Bash command such as `sed` or `cat`, or a language-specific tool. Both tools accept absolute paths and are limited only by the execution environment's file permissions. Tau does not restrict them to the repository.
|
|
133
122
|
|
|
134
123
|
### View image
|
|
135
124
|
|
|
136
|
-
`view_image` reads an image from the execution environment and
|
|
125
|
+
`view_image` reads an image from the execution environment and shows it to a model that accepts images. Tau's built-in instructions tell the agent to use it only when the user explicitly asks to view or analyze an image.
|
|
137
126
|
|
|
138
|
-
|
|
127
|
+
Supported formats are JPEG, PNG, and WebP, and the source file can be at most 50 MiB. An image is returned unchanged if both dimensions are at most 4,096 pixels and it is at most 3.5 MiB. A larger image is scaled down to fit within 4,096 pixels, keeping its aspect ratio; images are never scaled up. To meet the size limit, Tau tries lossless encoding first, then lossy compression, and reduces dimensions further only if needed. Transparency is kept. If a valid image still cannot fit the limit, the call fails. Relative paths resolve from the session's working directory.
|
|
139
128
|
|
|
140
129
|
## Command-line tools
|
|
141
130
|
|
|
142
|
-
`tau tool` provides standalone utilities for people and agents, usable from
|
|
131
|
+
`tau tool` provides standalone utilities for people and agents, usable from any shell, inside or outside Tau. Files, configuration, credentials, and required programs must be on the machine that runs the command. Agents run these commands through Bash.
|
|
143
132
|
|
|
144
133
|
| Command | Purpose | Guide |
|
|
145
134
|
| --- | --- | --- |
|
|
@@ -148,33 +137,33 @@ The supported formats are JPEG, PNG, and WebP. Source reads are capped at 50 MiB
|
|
|
148
137
|
| `tau tool speech-generate` | Generate narration or dialogue using ElevenLabs and assemble a WAV. | [Speech generation](speech-generation.md) |
|
|
149
138
|
| `tau tool openrouter` | Typed decisions and standalone text/media analysis. | [OpenRouter](openrouter.md) |
|
|
150
139
|
|
|
151
|
-
Each guide covers setup, input, examples, outputs, and
|
|
140
|
+
Each guide covers setup, input, examples, outputs, and failures. Run `tau tool --help` to list commands, or `tau tool <command> --help` for one command. Agents can read the same guides with `tau_docs`.
|
|
152
141
|
|
|
153
142
|
## Code-mode composition
|
|
154
143
|
|
|
155
|
-
`code` runs a one-
|
|
144
|
+
`code` runs a one-off JavaScript program that combines the enabled capabilities: `tau.web`, `tau.history`, `tau.nook`, `tau.mcp`, `tau.bash`, and `tau.models`. The Bash, write, edit, and image tools stay available as separate tools.
|
|
156
145
|
|
|
157
146
|
### Documentation and output
|
|
158
147
|
|
|
159
|
-
|
|
148
|
+
If the agent has not yet seen the runtime guide, it first runs a program that only prints it:
|
|
160
149
|
|
|
161
150
|
```js
|
|
162
151
|
printText(docs);
|
|
163
152
|
```
|
|
164
153
|
|
|
165
|
-
The guide covers runtime rules, capabilities, and
|
|
154
|
+
The guide covers runtime rules, capabilities, and examples. The agent reads each capability's reference it has not seen yet in a separate call that only prints documentation:
|
|
166
155
|
|
|
167
156
|
```js
|
|
168
157
|
printText(await tau.docs("web"));
|
|
169
158
|
```
|
|
170
159
|
|
|
171
|
-
The agent
|
|
160
|
+
The agent does not re-read documentation it has already seen. MCP tool descriptions and Nook's authoring guide are read in their own separate steps. Programs do not need to print intermediate results.
|
|
172
161
|
|
|
173
|
-
Only `printText(string)` and awaited `printImage({ data, mimeType })`
|
|
162
|
+
Only `printText(string)` and awaited `printImage({ data, mimeType })` produce output, in the order they are called. Return values are ignored. Text is truncated in the middle to `maxOutputTokens` (default 8,192; range 1–65,536). The agent leaves it unset unless needed, and may raise it to 16,384 on its own. Higher values require an explicit user request. When text from the built-in `code` tool is truncated, Tau saves it to a temporary file in the execution environment when possible and reports the path. The agent reads that file instead of running the program again with its side effects. The file does not contain images or text lost to capture limits.
|
|
174
163
|
|
|
175
|
-
JPEG, PNG, and WebP images are validated outside the sandbox and
|
|
164
|
+
JPEG, PNG, and WebP images are validated outside the sandbox and fitted to 4,096 pixels per dimension and 3.5 MiB each. Source images can be at most 40 megapixels, and a program can emit at most 16 images. Valid images are kept even if the built-in `code` program fails.
|
|
176
165
|
|
|
177
|
-
The
|
|
166
|
+
The helper functions `truncate(text, { maxChars, position? })` and `truncateLines(text, { maxLines, position? })` return shortened strings with a marker where text was removed. `position` defaults to `middle`; `start` and `end` keep that end of the text. They do not print anything.
|
|
178
167
|
|
|
179
168
|
```js
|
|
180
169
|
const result = await tau.bash.run({ command: "npm test" });
|
|
@@ -183,38 +172,30 @@ printText(truncate(result.stdout, { maxChars: 4000 }));
|
|
|
183
172
|
|
|
184
173
|
### Execution and limits
|
|
185
174
|
|
|
186
|
-
Programs have no
|
|
175
|
+
Programs have no direct access to files, processes, environment variables, credentials, imports, timers, or the network. They can act only through the capabilities. Keep data in variables, and use `tau.bash` for files. There is no scratch-file API.
|
|
187
176
|
|
|
188
|
-
`code`
|
|
177
|
+
`code` times out after 5 minutes by default. `timeout` accepts 1–900,000 ms (15 minutes). `tau.bash.run` times out after 60 seconds by default, and at most after 5 minutes or the program's own deadline, whichever comes first. A program can make 128 API requests, eight at a time. Each serialized request and response can be at most 64 MiB. Object properties set to `undefined` are dropped, while `undefined` arguments and array entries are rejected. Programs are never retried, and failure or cancellation does not undo actions already taken.
|
|
189
178
|
|
|
190
179
|
### Capabilities
|
|
191
180
|
|
|
192
|
-
- `tau.web`: metadata discovery, Exa search, and page content
|
|
193
|
-
- `tau.history`: read-only search and paginated
|
|
194
|
-
- `tau.nook`:
|
|
195
|
-
- `tau.mcp`:
|
|
196
|
-
- `tau.bash`: `run`, `start`, `list`, `read`, `wait`, and `stop`. `run` returns stdout
|
|
197
|
-
- `tau.models`: lists fixed OpenRouter
|
|
198
|
-
|
|
199
|
-
SDK and command client tools use the same sandbox globals and output contract with their own explicitly declared APIs. Their default program deadline is 60 seconds unless configured otherwise.
|
|
181
|
+
- `tau.web`: metadata discovery, Exa search, and fetching page content. The agent prefers local data, dedicated CLIs, first-party APIs, and structured sources over scraping web pages. For GitHub it uses `gh` or a Git checkout where suitable. Metadata discovery works without an Exa key; search and content fetching need one.
|
|
182
|
+
- `tau.history`: read-only search and paginated transcripts. The agent uses it only when explicitly told to look at past sessions. It treats past content as data and never follows instructions in it. See [history](history.md).
|
|
183
|
+
- `tau.nook`: deploying sites, templates, and each site's JSON KV store. The agent uses it when the user asks to publish or manage Nook. Before writing an app, the agent reads `tau.nook.skill()` in a separate call that only prints documentation. See [Nook](nook.md).
|
|
184
|
+
- `tau.mcp`: finding and calling tools and resources on connected MCP servers. The agent reads each tool's description and schema before calling it. Connections are shared and opened on first use, and calls that change data are never retried. An `isError` result is returned as data, while protocol failures throw. MCP server configuration and trust rules apply. See [configuration reference](config-reference.md#mcpservers) and [security](security.md#trust-mcp-servers).
|
|
185
|
+
- `tau.bash`: `run`, `start`, `list`, `read`, `wait`, and `stop`. `run` returns stdout, stderr, and exit and termination fields, capturing up to 24 MiB. Beyond that it keeps the end, so check `truncated` before parsing. Optional UTF-8 `stdin` is limited to 16 MiB and closed after writing. Without `stdin` the command has no stdin at all, while `""` gives it an empty one. `start` takes no stdin. Background jobs are the same jobs as the Bash tools', with the same output limits. Jobs survive the program ending and interruption, while foreground commands are cancelled. The shell rules above apply.
|
|
186
|
+
- `tau.models`: lists a fixed set of OpenRouter models and runs standalone chats or typed decisions with them. These calls do not see the session's conversation or tools. Chat media can be paths on the agent's machine or inline padded base64 with a matching MIME type. Credentials stay on the host. Provider usage data is returned, but these charges are not included in the session's cost or usage logs. Requests can be cancelled and are never retried automatically. Limits on input, models, media, responses, and requests are the same as in [OpenRouter](openrouter.md). Check whether a response completed or was refused instead of assuming it is a full answer.
|
|
200
187
|
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
A subagent can receive only:
|
|
204
|
-
|
|
205
|
-
```text
|
|
206
|
-
bash write edit view_image web history nook mcp models
|
|
207
|
-
```
|
|
188
|
+
SDK and command client tools built on code mode use the same sandbox functions and output rules, with their own declared APIs. Their programs time out after 60 seconds unless configured otherwise.
|
|
208
189
|
|
|
209
|
-
|
|
190
|
+
## Subagent tools
|
|
210
191
|
|
|
211
|
-
|
|
192
|
+
A subagent gets each of `bash`, `write`, `edit`, `view_image`, `web`, `history`, `nook`, `mcp`, and `models` that the main persona also has, plus `tau_docs`. It never gets the subagent tools or client tools. Its Bash and file tools start in the subagent's working directory. [Subagents](subagents.md#tools) has the details.
|
|
212
193
|
|
|
213
194
|
## Client-owned tools
|
|
214
195
|
|
|
215
|
-
The TUI
|
|
196
|
+
The TUI offers `diff_review` and `prefill_input` unless client tools are disabled. `diff_review` reads repository state from the execution environment and runs the review interface on the TUI machine. `prefill_input` puts a draft in an empty TUI editor. It never sends the text and refuses to overwrite an existing draft.
|
|
216
197
|
|
|
217
|
-
Configured command client tools
|
|
198
|
+
Configured command client tools also belong to the client. They run processes on the client machine, and can run limited commands in the execution environment when the work belongs on the session machine. This matters with remote attachment, where the TUI and its tools may be on a laptop while the host and execution environment are elsewhere. See [client tools](client-tools.md) for configuration, protocol helpers, and limits, and [TUI](tui.md) for diff-tool configuration.
|
|
218
199
|
|
|
219
200
|
### Sending files to Telegram
|
|
220
201
|
|
|
@@ -227,23 +208,23 @@ Telegram provides four client tools, each accepting `{ path, caption? }` and del
|
|
|
227
208
|
| `send_audio_to_telegram` | Audio player | MP3/M4A | 50,000,000 bytes |
|
|
228
209
|
| `send_document_to_telegram` | Original file attachment | Any type, including PDF, CSV, ZIP, WAV, and original-quality images | 50,000,000 bytes |
|
|
229
210
|
|
|
230
|
-
Paths may be absolute or relative to the session working directory. Captions are plain text
|
|
211
|
+
Paths may be absolute or relative to the session's working directory. Captions are plain text of at most 1,024 UTF-16 code units. Documents keep their original bytes and filename, while photos go through Telegram's own photo processing. File contents never enter the model's context or the session history.
|
|
231
212
|
|
|
232
|
-
|
|
213
|
+
Files are read in chunks of at most 8,000,000 bytes. A file that is not a regular file, is empty, is too large, or changes during the transfer is rejected. The tools do not inspect codecs, convert files, or try another delivery method. Telegram checks media compatibility, including photo dimensions. Convert unsupported media before sending, or send it as a document.
|
|
233
214
|
|
|
234
|
-
|
|
215
|
+
Read errors, cancellation, and Telegram delivery errors fail the tool call. Each call has five minutes and is never retried automatically, because an interrupted upload may already have reached Telegram.
|
|
235
216
|
|
|
236
|
-
The runner
|
|
217
|
+
The runner holds the upload credentials, and the recipient is always the session's bot and chat; the agent cannot choose another. These tools are not affected by `enabledClientTools` and do not exist in TUI sessions or subagents. Viewing an image with `view_image` does not send it to Telegram. Automatic voice replies through `/tts_on` are separate from these tools.
|
|
237
218
|
|
|
238
219
|
## When a tool is missing or fails
|
|
239
220
|
|
|
240
|
-
First
|
|
221
|
+
First work out where the tool should come from:
|
|
241
222
|
|
|
242
|
-
- For a host tool,
|
|
243
|
-
- For a subagent tool,
|
|
244
|
-
- For a client tool, confirm that an observing client
|
|
245
|
-
-
|
|
223
|
+
- For a host tool, check the active persona's `tools`, the host configuration, and service credentials.
|
|
224
|
+
- For a subagent tool, check the main persona's `tools` against the list of tools subagents can receive.
|
|
225
|
+
- For a client tool, confirm that an attached, observing client offers it and that client tools are not disabled.
|
|
226
|
+
- If `tau_docs` is missing, something is wrong with the Tau installation or version; no persona setting removes it.
|
|
246
227
|
|
|
247
|
-
Then check
|
|
228
|
+
Then check which machine the error comes from. A path on the TUI machine may not exist in the execution environment. A command in the host's `PATH` may be missing from the execution environment's login shell. Errors from a client tool's own process come from the client machine, while `executionEnvironment.exec` errors come from the session machine.
|
|
248
229
|
|
|
249
|
-
Use `tau --debug --persona <id>`
|
|
230
|
+
Use `tau --debug --persona <id>` to see the host tool schemas for a new local session. `/reload` reloads configuration and persona content in an idle session, but it does not restart or refresh tools that an attached client offers. See [troubleshooting](troubleshooting.md) and [security](security.md) for boundary-specific checks.
|