Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

docs: add gitbooks pages for hooks, web search, notifications, and orchestration

Steven Enamakel4f486ed9a577
diff --git a/gitbooks/developing/hooks.md b/gitbooks/developing/hooks.md
index d1ca9a1947..5442df6331 100644
--- a/gitbooks/developing/hooks.md
+++ b/gitbooks/developing/hooks.md
@@ -7,21 +7,11 @@ icon: link
# Hooks
-A hook is a script you own that OpenHuman runs at a specific moment (before a
-tool executes, after a file is edited, when a turn finishes) and whose answer
-the agent obeys. It is how you make the agent follow a rule that lives in your
-repository rather than in our code: block `rm -rf`, run the formatter after every
-edit, write an audit line per tool call, refuse to read `.env`.
-
-The contract is deliberately the same as
-[Cursor's](https://cursor.com/docs/hooks): same file name, same event names,
-same stdin envelope, same stdout decision, same exit codes. A hook script written
-for either host runs on the other unchanged.
-
-> There is a second, unrelated meaning of "hook" in this codebase: the in-process
-> Rust traits in `crates/openhuman-core/src/agent/hooks.rs` that an *embedding host* installs
-> by compiling against the core. Those are for building a product on top of
-> OpenHuman. This page is about the file-based kind, for using OpenHuman.
+A hook is a script you own. OpenHuman runs it at a set moment, such as before a tool runs, after a file is edited or when a turn finishes, and the agent obeys its answer. Hooks let you enforce rules that live in your repository instead of in our code. You can block `rm -rf`, run the formatter after every edit, write an audit line per tool call, or refuse to read `.env`.
+
+The contract matches [Cursor's](https://cursor.com/docs/hooks): the same file name, event names, stdin envelope, stdout decision and exit codes. A hook script written for either host runs on the other unchanged.
+
+> "Hook" has a second, unrelated meaning in this codebase: the in-process Rust traits in `crates/openhuman-core/src/agent/hooks.rs`. An embedding host installs those by compiling against the core. This page is about the file-based kind.
## The file
@@ -46,8 +36,7 @@ for either host runs on the other unchanged.
}
```
-Four locations are read, and **they concatenate: a more specific file cannot
-remove a broader one's rules**:
+OpenHuman reads four locations and concatenates them. A more specific file cannot remove a broader file's rules.
| Layer | Path |
| ----- | ---- |
@@ -56,53 +45,45 @@ remove a broader one's rules**:
| Workspace | `<workspace_dir>/hooks.json` |
| Project | `<action_dir>/.openhuman/hooks.json` |
-Concatenation is safe because the **strictest verdict wins**: across every hook
-that ran, deny beats ask beats allow. Adding a hook can never loosen a policy
-another one set, which is what lets a repository ship its own `hooks.json` onto
-a machine an operator has already locked down.
+Concatenation is safe because the strictest verdict wins. Across every hook that ran, deny beats ask, and ask beats allow. Adding a hook never loosens a policy that another hook set. A repository can therefore ship its own `hooks.json` onto a machine an operator has already locked down.
### Fields
| Field | Meaning |
| ----- | ------- |
-| `command` | Program to run (or the prompt text, for `"type": "prompt"`). Runs with its own `hooks.json` directory as cwd. |
+| `command` | Program to run, or the prompt text for `"type": "prompt"`. It runs with the directory of its `hooks.json` as the working directory. |
| `type` | `command` (default) or `prompt`. |
-| `matcher` | Which occurrences reach this hook, see below. Absent means all. |
+| `matcher` | Which occurrences reach this hook. See Matchers below. Absent means all. |
| `timeout` | Seconds. Falls back to `[hooks] default_timeout_secs` (30). |
-| `failClosed` | Treat a crashed, missing, or timed-out hook as a denial. Default `false`. |
+| `failClosed` | Treat a crashed, missing or timed-out hook as a denial. Default `false`. |
| `loop_limit` | Follow-ups this hook may inject per session. Default 5; `0` means unlimited. |
| `model` | Model override for a `prompt` hook. |
| `enabled` | Set `false` to park a hook without deleting it. |
## The protocol
-The event arrives on **stdin** as one JSON object. The decision goes to
-**stdout**. The exit code decides how stdout is read:
+The event arrives on stdin as one JSON object. The decision goes to stdout. The exit code decides how stdout is read:
| Exit | Meaning |
| ---- | ------- |
| `0` | stdout is the decision. Empty stdout is a no-op. |
| `2` | Deny, whatever stdout said. stderr becomes the reason the agent is told. |
-| anything else | Failure. **Fails open** (the action proceeds) unless `failClosed`. |
+| anything else | Failure. It fails open (the action proceeds) unless `failClosed` is set. |
-A timeout, a missing interpreter, and unparseable stdout all take that same
-failure path. That symmetry is the point: a hook that denies only when it
-manages to run is not a security control, so `failClosed` covers every way a
-script can fail to answer.
+A timeout, a missing interpreter and unparseable stdout all take the same failure path. A hook that denies only when it manages to run is not a security control, so `failClosed` covers every way a script can fail to answer.
-stdout is parsed leniently: the last standalone JSON object wins, so a script
-that logs progress before answering works as written.
+stdout is parsed leniently. The last standalone JSON object wins, so a script that logs progress before answering works as written.
### Decision object
-Every field is optional, and each event honours the subset it defines:
+Every field is optional. Each event honors the subset it defines:
```json
{
"permission": "allow" | "deny" | "ask",
"user_message": "shown to the human",
"agent_message": "shown to the model",
- "updated_input": { "…": "replacement tool arguments" },
+ "updated_input": { "...": "replacement tool arguments" },
"additional_context": "appended to the tool result",
"continue": false,
"followup_message": "sent as another user turn",
@@ -110,22 +91,18 @@ Every field is optional, and each event honours the subset it defines:
}
```
-`ask` escalates to the approval gate where one is available; inside the tool
-middleware, which has no approval channel, it denies rather than quietly
-allowing.
+`ask` goes to the approval gate where one exists. Inside the tool middleware, which has no approval channel, it denies instead of quietly allowing.
## Events
-`hook_event_name` in the envelope tells a script which moment it is in. Names are
-matched loosely: `preToolUse`, `PreToolUse` and `pre_tool_use` are the same
-event, and Claude Code's `UserPromptSubmit` aliases onto `beforeSubmitPrompt`.
+`hook_event_name` in the envelope tells a script which moment it is in. Names match loosely: `preToolUse`, `PreToolUse` and `pre_tool_use` are the same event, and Claude Code's `UserPromptSubmit` maps to `beforeSubmitPrompt`.
-| Event | Fires | Honours |
+| Event | Fires | Honors |
| ----- | ----- | ------- |
| `preToolUse` | before any tool | `permission`, `updated_input`, `agent_message` |
| `postToolUse` | after a tool succeeded | `additional_context` |
| `postToolUseFailure` | after a tool failed | - |
-| `beforeShellExecution` | before `shell` / `node_exec` / … | `permission`, `agent_message` |
+| `beforeShellExecution` | before `shell` / `node_exec` / ... | `permission`, `agent_message` |
| `afterShellExecution` | after one completed | - |
| `beforeReadFile` | before `file_read` / `read_diff` | `permission` |
| `afterFileEdit` | after `file_write` / `edit` / `apply_patch` | - |
@@ -136,30 +113,15 @@ event, and Claude Code's `UserPromptSubmit` aliases onto `beforeSubmitPrompt`.
| `stop` | after a turn | `followup_message` |
| `afterAgentResponse` | on the assistant's message | - |
-`sessionStart`, `sessionEnd`, `preCompact`, `afterAgentThought` and `subagentStop`
-are defined: they parse, match, execute, and can be exercised with `hooks test`,
-but the core does not fire them yet. (`subagentStop` is the near miss: the handler
-`hooks::ops::subagent_stopped` is complete, but the in-progress
-`agent/subagent_host` cutover currently fires only `subagentStart` and returns
-without ever calling the stop side.) Configuring one
-produces a load warning saying so, and `hooks list` reports `"wired": false` for
-it. That is deliberate: a hook that silently never runs is the worst thing this
-system can do to you.
+`sessionStart`, `sessionEnd`, `preCompact`, `afterAgentThought` and `subagentStop` are defined. They parse, match and execute, and you can exercise them with `hooks test`, but the core does not fire them yet. Configuring one produces a load warning, and `hooks list` reports `"wired": false` for it. A hook that silently never runs would be worse, so the warning is deliberate.
### Derived events
-OpenHuman has no separate "shell execution" or "file read" call site: those are
-the `shell`, `file_read` and `file_write` tools going through the ordinary tool
-seam. So the shell, file and MCP events are *derived* from tool calls, and their
-payloads are reshaped the way a Cursor hook expects: a `command` string, a
-`file_path`, an `edits` array. Both the generic `preToolUse` and the specialised
-event fire, generic first.
+OpenHuman has no separate "shell execution" or "file read" call site. Those are the `shell`, `file_read` and `file_write` tools going through the ordinary tool path. The shell, file and MCP events are therefore derived from tool calls, and their payloads are reshaped the way a Cursor hook expects: a `command` string, a `file_path`, an `edits` array. The generic `preToolUse` fires first, then the specialized event.
## Matchers
-One string, matched against a subject the event chooses: the tool name for tool
-events, the command line for shell events, the path for file events, the agent id
-for subagent events.
+A matcher is one string, matched against a subject the event chooses. That is the tool name for tool events, the command line for shell events, the path for file events and the agent id for subagent events.
* absent or `*`: everything
* `Shell`: a literal, case-insensitive name
@@ -167,17 +129,13 @@ for subagent events.
* `MCP:search_docs`: an MCP tool by name
* anything containing punctuation: a regular expression (`^rm\b`, `\.rs$`)
-An invalid regex matches **nothing** and logs.
+An invalid regex matches nothing and is logged.
## Latency
-Gating events run their hooks sequentially and the turn waits; a denial
-short-circuits the rest. Observational events (`afterShellExecution`,
-`postToolUseFailure`, `afterAgentResponse`, …) are dispatched onto a background
-task and the turn never waits, so an audit hook that hangs must not hang the agent.
+Gating events run their hooks one after another and the turn waits. A denial skips the rest. Observational events (`afterShellExecution`, `postToolUseFailure`, `afterAgentResponse` and others) run on a background task and the turn never waits, so a hung audit hook cannot hang the agent.
-When nothing is configured, the harness bridge is not installed at all, so an
-unconfigured host pays nothing per tool call.
+When nothing is configured, the harness bridge is not installed, so an unconfigured host pays nothing per tool call.
## Environment
@@ -189,20 +147,17 @@ Hook processes inherit the core's environment plus:
## Prompt hooks
-`"type": "prompt"` writes the policy in English instead of shell. The text is
-sent to a model with the event JSON substituted for `$ARGUMENTS`, and the model
-answers `{"ok": true}` or `{"ok": false, "reason": "…"}`.
+With `"type": "prompt"` you write the policy in English instead of shell. The text goes to a model with the event JSON substituted for `$ARGUMENTS`, and the model answers `{"ok": true}` or `{"ok": false, "reason": "..."}`.
```json
{ "command": "Deny if $ARGUMENTS deletes anything outside /tmp.", "type": "prompt" }
```
-It costs a model call per event, so put it on rare, high-stakes moments, not on
-every tool call.
+Each event costs a model call, so use prompt hooks for rare, high-stakes moments, not every tool call.
## Inspecting and debugging
-Three RPC methods, on the `hooks` namespace:
+Three commands cover it:
```bash
openhuman-core hooks list # what is configured, from which file, and whether it is wired
@@ -211,13 +166,9 @@ openhuman-core hooks test --event beforeShellExecution \
--payload '{"command":"rm -rf /","sandbox":false}'
```
-Over JSON-RPC the same three are `openhuman.hooks_list`, `openhuman.hooks_reload`
-and `openhuman.hooks_test`.
+Over JSON-RPC they are `openhuman.hooks_list`, `openhuman.hooks_reload` and `openhuman.hooks_test`.
-`hooks test` fires one synthetic event in the foreground and reports what each
-matching hook decided, including hooks for observational events that a real
-dispatch would run detached. Debug a hook with it rather than by asking the agent
-to do the dangerous thing to see whether the rule fires.
+`hooks test` fires one synthetic event in the foreground and reports what each matching hook decided. That includes hooks on observational events, which a real dispatch would run in the background. Use it to debug a hook instead of asking the agent to do the dangerous thing to see whether the rule fires.
## Host switches
@@ -254,7 +205,7 @@ echo '{"permission":"deny","agent_message":"Secrets files are off limits. Ask th
```sh
#!/bin/sh
-cat > /dev/null # drain stdin; this hook does not read the event
+cat > /dev/null # drain stdin, this hook ignores the event
cargo fmt >/dev/null 2>&1
echo '{}'
```
@@ -263,12 +214,6 @@ Both need `chmod +x`.
## Implementation
-The engine and the whole `hooks.json` contract live upstream, in
-`tinyagents_runtime::command_hooks`: the types, the file and its layering, the
-matcher, running one hook (stdin, timeout, exit codes), selection and ordering
-and aggregation, the context envelope, and follow-ups.
+The engine and the whole `hooks.json` contract live upstream in `tinyagents_runtime::command_hooks`. That covers the types, the file and its layering, the matcher, running one hook (stdin, timeout, exit codes), selection, ordering and aggregation, the context envelope, and follow-ups.
-What stays in `crates/openhuman-core/src/hooks/` is the host half: `bridge`
-(mounting the engine on the harness's existing tool and turn seams), `ops` (the
-moments with no existing seam), `host`, `schemas` (the RPC surface) and
-`prompt_eval`. The beside-code `README.md` there is the authoritative split.
+`crates/openhuman-core/src/hooks/` holds the host half: `bridge` (mounts the engine on the harness's tool and turn paths), `ops` (moments with no existing path), `host`, `schemas` (the RPC surface) and `prompt_eval`. The `README.md` beside the code is the authoritative split.
diff --git a/gitbooks/features/native-tools/web-search.md b/gitbooks/features/native-tools/web-search.md
index fa9ee981ed..e42129a734 100644
--- a/gitbooks/features/native-tools/web-search.md
+++ b/gitbooks/features/native-tools/web-search.md
@@ -5,11 +5,11 @@ description: >-
icon: magnifying-glass
---
-# Web Search
+# Web search
-The agent can search the live web, get a grounded answer with citations, and read pages on its own. Out of the box this runs on providers **included with TinyHumans**: [Exa](https://exa.ai) for search and page contents, and [Gemini](https://ai.google.dev) with Google Search grounding for answers. You don't need a search API key for either. You can add more providers with your own key, and several providers can be on at the same time.
+The agent can search the live web, get a grounded answer with citations, and read pages on its own. Out of the box it runs on providers included with TinyHumans: [Exa](https://exa.ai) for search and page contents, and [Gemini](https://ai.google.dev) with Google Search grounding for answers. You do not need a search API key for either. You can add more providers with your own key, and several can be on at once.
-## What it's good for
+## What it is good for
- Research: "what's the latest on X".
- Citation hunting: "find me three sources for Y".
@@ -18,15 +18,15 @@ The agent can search the live web, get a grounded answer with citations, and rea
## Roles: one tool per job
-The agent sees one tool per **capability role**, whichever providers are on:
+The agent sees one tool per capability role, whichever providers are on:
| Role | Agent tool | What it returns |
| ------------ | ------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-| **Search** | `web_search_tool` | Ranked results: title, URL, publish date and an excerpt. |
-| **Answer** | `web_answer_tool` | A written answer grounded in web sources, with citations. With `depth: "deep"` it runs Gemini Deep Research instead, which needs your own Gemini key. |
-| **Contents** | `web_contents_tool` | The extracted text of the URLs it is given. |
+| Search | `web_search_tool` | Ranked results: title, URL, publish date and an excerpt. |
+| Answer | `web_answer_tool` | A written answer grounded in web sources, with citations. With `depth: "deep"` it runs Gemini Deep Research instead, which needs your own Gemini key. |
+| Contents | `web_contents_tool` | The extracted text of the URLs it is given. |
-Each role has an ordered provider list. The first **usable** provider serves the call; if it fails, the next one is tried, and so on. The result says which provider answered and which were skipped, for example `Answer for: … (via Gemini, after Exa)`, and the chat card shows the same "via Gemini, after Exa" note under the answer and its sources. A role with no usable provider has no tool at all, so the agent never sees a tool that can't run.
+Each role has an ordered provider list. The first usable provider serves the call. If it fails, the next one is tried, and so on. The result says which provider answered and which were skipped, for example `Answer for: … (via Gemini, after Exa)`, and the chat card shows the same "via Gemini, after Exa" note under the answer and its sources. A role with no usable provider has no tool at all, so the agent never sees a tool that cannot run.
The default order is:
@@ -40,10 +40,10 @@ Providers that are off are skipped, so with the defaults only Exa and Gemini ser
## Providers and routes
-Every provider has a **route**:
+Every provider has a route:
-- **Included with TinyHumans** (`managed`): the call goes through the TinyHumans backend and is billed to your TinyHumans balance. It needs a signed-in session. No key is stored on your machine.
-- **Own key** (`direct`): the call goes straight from your machine to the provider with your API key.
+- Included with TinyHumans (`managed`): the call goes through the TinyHumans backend and is billed to your TinyHumans balance. It needs a signed-in session. No key is stored on your machine.
+- Own key (`direct`): the call goes straight from your machine to the provider with your API key.
| Provider | Routes | Roles | Notes |
| -------- | ------------------ | ------------------------- | ----------------------------------------------------------------------------------------------------- |
@@ -57,7 +57,7 @@ Every provider has a **route**:
| Seltz | Own key | Search | Off by default. |
| SearXNG | Own instance | Search | Off by default. Uses the URL of your own [SearXNG](https://docs.searxng.org/) instance, not a key. |
-A provider is **usable** when it is on, its route is available (you are signed in for the included route, or a key is saved for the own-key route), and search as a whole is on. The settings page shows this as a badge on each provider: **Ready**, **Needs key**, **Sign in required**, or **Off**.
+A provider is usable when it is on, its route is available (you are signed in for the included route, or a key is saved for the own-key route), and search as a whole is on. The settings page shows this as a badge on each provider: Ready, Needs key, Sign in required or Off.
If you use OpenHuman without signing in (a local session), the included route is unavailable. Turn on a provider with your own key to keep web search working.
@@ -67,13 +67,13 @@ When your TinyHumans balance runs out, included providers stop answering and the
Everything is under **Connections → Search**:
-- **Web search**: one switch turns every search tool on or off.
-- **Providers**: one card per provider with an on/off switch, the route choice (for providers that support both), the API key field for the own-key route, and the instance URL for SearXNG. Gemini always shows its key field, since the key is what enables Deep Research.
-- **Roles**: the provider order for Search, Answer and Contents, with which provider currently serves each role. Move providers up or down, remove fallbacks, add a provider back, or reset a role to its default order.
-- **Allowed websites**: which sites the assistant may open and read through web fetch and the browser tool. This list does not restrict web search.
-- **Advanced → Expose each provider's own tools**: gives the agent each usable provider's own tools (for example Brave news or image search, or Exa's find-similar) rather than one tool per role. This uses more of the context window.
+- Web search: one switch turns every search tool on or off.
+- Providers: one card per provider with an on/off switch, the route choice (for providers that support both), the API key field for the own-key route, and the instance URL for SearXNG. Gemini always shows its key field, since the key is what enables Deep Research.
+- Roles: the provider order for Search, Answer and Contents, with which provider currently serves each role. Move providers up or down, remove fallbacks, add a provider back, or reset a role to its default order.
+- Allowed websites: which sites the assistant may open and read through web fetch and the browser tool. This list does not restrict web search.
+- Advanced → Expose each provider's own tools**: gives the agent each usable provider's own tools (for example Brave news or image search, or Exa's find-similar) rather than one tool per role. This uses more of the context window.
-Keys are stored in `config.toml`. When secret encryption is on, OpenHuman stores them as ciphertext; the OS keyring protects the master encryption key, not the provider keys themselves.
+Keys are stored in `config.toml`. When secret encryption is on, OpenHuman stores them as ciphertext. The OS keyring protects the master encryption key, not the provider keys themselves.
### Configuration file and environment
@@ -105,9 +105,9 @@ Environment overrides:
| Variable | Effect |
| ---------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ |
| `OPENHUMAN_SEARCH_ENABLED` | Turns search on or off. |
-| `OPENHUMAN_SEARCH_PROVIDERS` | Replaces the provider set, e.g. `exa:managed,gemini,brave`. |
-| `OPENHUMAN_SEARCH_ROUTES` | Changes routes, e.g. `exa=direct,gemini=managed`. |
-| `OPENHUMAN_SEARCH_ROLES` | Sets role orders, e.g. `search=brave\|exa;answer=gemini`. |
+| `OPENHUMAN_SEARCH_PROVIDERS` | Replaces the provider set, for example `exa:managed,gemini,brave`. |
+| `OPENHUMAN_SEARCH_ROUTES` | Changes routes, for example `exa=direct,gemini=managed`. |
+| `OPENHUMAN_SEARCH_ROLES` | Sets role orders, for example `search=brave\|exa;answer=gemini`. |
| `OPENHUMAN_EXA_API_KEY`, `OPENHUMAN_GEMINI_API_KEY`, `OPENHUMAN_BRAVE_API_KEY`, `OPENHUMAN_TAVILY_API_KEY`, `OPENHUMAN_QUERIT_API_KEY`, `OPENHUMAN_PARALLEL_API_KEY`, `OPENHUMAN_SELTZ_API_KEY` | Provider keys. The unprefixed names (`EXA_API_KEY`, `GEMINI_API_KEY`, …) work too. |
Treat environment-provided keys as secrets.
@@ -118,14 +118,14 @@ Besides serving the Search role, an enabled SearXNG instance is exposed to RPC a
## Parallel is own-key only
-Parallel is no longer included with TinyHumans; it works only with your own Parallel key. A saved Parallel key carries over when you upgrade (Parallel stays first for search if it was your chosen engine). A setup that relied on the included Parallel route without a key moves to the included Exa and Gemini providers. `OPENHUMAN_PARALLEL_ROUTE` is ignored.
+Parallel works only with your own Parallel key. A Parallel key saved before this change carries over on upgrade, and Parallel stays first for search if it was your chosen engine. A setup that used the included Parallel route without a key moves to the included Exa and Gemini providers. `OPENHUMAN_PARALLEL_ROUTE` is ignored.
## How it differs from generic HTTP
-A plain `http_request` tool can fetch a URL but can't _find_ one. Web search is the discovery layer: it finds the right URLs, and the Contents role (or the [Web Scraper](web-scraper.md)) reads them.
+A plain `http_request` tool can fetch a URL but cannot find one. Web search finds the right URLs, and the Contents role (or the [web scraper](web-scraper.md)) reads them.
## See also
- [MCP Server](../../developing/mcp-server.md): how `searxng_search` appears to MCP clients.
-- [Web Scraper](web-scraper.md): fetch and clean a specific URL.
-- [Smart Token Compression](../token-compression.md): search snippets are compressed before they reach the model.
+- [Web scraper](web-scraper.md): fetch and clean a specific URL.
+- [Token compression](../token-compression.md): search snippets are compressed before they reach the model.
diff --git a/gitbooks/features/notifications-and-activity.md b/gitbooks/features/notifications-and-activity.md
index bfb3d2b16d..53b3cc027e 100644
--- a/gitbooks/features/notifications-and-activity.md
+++ b/gitbooks/features/notifications-and-activity.md
@@ -1,91 +1,82 @@
---
description: >-
- The notification center, the quiet notice tray, and where background work
- now surfaces: everything OpenHuman tells you about, and everything it does
- while you are not watching.
+ The notification center, the notice tray, and where background work shows
+ up: what OpenHuman tells you about, and what it does while you are away.
icon: bell
---
-# Notifications & Activity
+# Notifications and activity
-OpenHuman surfaces two kinds of "what's happening": **notifications** (things you should look at, like an important Slack message, a failed webhook, or a high-priority email) and **activity** (a ledger of what the agent did on its own while you weren't watching).
+OpenHuman shows two kinds of "what is happening". Notifications are things you should look at, like an important Slack message, a failed webhook or a high-priority email. Activity is a record of what the agent did on its own while you were not watching.
-Both live on the **Notifications** page. There is no longer an Activity hub or a Routines screen. Both addresses still resolve, but not to what they used to show: `/activity` redirects to **Settings → Account**, and `/routines` to [Workflows](workflows.md). The notification feeds moved here, and the scheduler moved to Workflows → Schedules.
+Both live on the Notifications page. There is no Activity hub or Routines screen. `/activity` redirects to **Settings → Account**, and `/routines` redirects to [Workflows](workflows.md). The scheduler lives under Workflows → Schedules.
----
-
-## Notification Center
+## Notification center
-The notification center is fed by two independent streams, which render as two stacked sections on the Notifications page.
+Two independent streams feed the notification center. They show as two stacked sections on the Notifications page.
### Integration notifications
-Notifications captured from connected accounts (Gmail, Slack, WhatsApp, Discord, …) are ingested through the `notification.ingest` RPC, persisted to a per-workspace SQLite store, and then **triaged by a local LLM in the background**. Ingest returns immediately; triage runs in a spawned task and back-fills the score a moment later, so a freshly arrived item can briefly show as unscored.
-
-Triage assigns each notification an **action**, which maps to a fixed importance score between 0.0 and 1.0:
+Notifications from connected accounts (Gmail, Slack, WhatsApp, Discord and others) come in through the `notification.ingest` RPC. They are saved to a per-workspace SQLite store, then triaged by a local LLM in the background. Ingest returns immediately. Triage runs in a spawned task and fills in the score a moment later, so a new item can briefly show as unscored.
-| Triage action | Score | What it means |
-| ------------- | ----- | -------------------------------- |
-| `drop` | 0.10 | Noise, not worth surfacing |
-| `acknowledge` | 0.35 | Low value, informational |
-| `react` | 0.65 | Worth a follow-up |
-| `escalate` | 0.90 | High priority, hand to the agent |
+Triage gives each notification an action, which maps to a fixed importance score from 0.0 to 1.0:
-Only `react` and `escalate` are considered "routed" actions; `drop` and `acknowledge` stay quiet. Each ingested item carries a one-sentence `triage_reason` justifying the classifier's call, plus a lifecycle status: **unread → read → acted → dismissed**. Duplicate content received within a 60-second window collapses to a single entry.
+| Triage action | Score | What it means |
+| --- | --- | --- |
+| `drop` | 0.10 | Noise, not worth surfacing |
+| `acknowledge` | 0.35 | Low value, informational |
+| `react` | 0.65 | Worth a follow-up |
+| `escalate` | 0.90 | High priority, hand to the agent |
-### System (core-bridge) notifications
+Only `react` and `escalate` are routed. `drop` and `acknowledge` stay quiet. Each item carries a one-sentence `triage_reason` explaining the call, and a status that moves from unread to read to acted to dismissed. Duplicate content received within 60 seconds collapses into one entry.
-The second stream translates selected internal events into compact, user-facing alerts and pushes them over the socket bridge as they happen. These are persisted before broadcast, so anything fired while the app was closed syncs down on the next open. Each carries a **category** and an in-app deep link:
+### System notifications
-| Source event | Category | Surfaces when |
-| -------------------- | -------- | ----------------------------------------- |
-| Cron job completed | Agents | Always (success or failure) |
-| Webhook processed | System | **Only on failure**; successes are silent |
-| Sub-agent finished | Agents | Always |
-| Sub-agent failed | Agents | Always |
-| Notification triaged | Agents | Only when routed (`escalate`/`react`) |
-| API key rejected | System | Always; links to the LLM settings tab |
+The second stream turns selected internal events into short alerts and pushes them over the socket bridge as they happen. They are saved before they are sent, so anything fired while the app was closed syncs on the next open. Each has a category and an in-app deep link:
-The category set the notification center understands is **messages, agents, skills, system, meetings, reminders, important**. The page shows a filter chip row, but only for the categories that actually appear in the current feed, plus **Mark all read** and **Clear**. Clicking a notification marks it read and follows its deep link. Some core notifications carry **action buttons** and are pinned to the top. The feed holds the most recent 200 items.
+| Source event | Category | Shows when |
+| --- | --- | --- |
+| Cron job completed | Agents | Always (success or failure) |
+| Webhook processed | System | Only on failure. Successes are silent. |
+| Sub-agent finished | Agents | Always |
+| Sub-agent failed | Agents | Always |
+| Notification triaged | Agents | Only when routed (`escalate` or `react`) |
+| API key rejected | System | Always. Links to the LLM settings tab. |
-### Per-provider routing & thresholds
+The categories are messages, agents, skills, system, meetings, reminders and important. The page shows filter chips only for categories present in the current feed, plus **Mark all read** and **Clear**. Clicking a notification marks it read and follows its deep link. Some system notifications have action buttons and are pinned to the top. The feed holds the most recent 200 items.
-Every provider has its own settings (`notification.settings_set`), letting you tune the noise per source:
+### Per-provider routing and thresholds
-| Setting | Effect |
-| ----------------------- | ------------------------------------------------------------------------------ |
-| `enabled` | When off, that provider's notifications are not ingested at all |
-| `importance_threshold` | Minimum score (0.0 to 1.0) to display; `0.0` shows everything |
-| `route_to_orchestrator` | When on, high-importance (`react`/`escalate`) items are forwarded to the agent |
+Each provider has its own settings (`notification.settings_set`), so you can tune the noise per source:
-Auto-routing re-reads the provider's settings the moment before escalating, so toggling a setting mid-flight takes effect immediately. A notification is only routed to the agent when its score clears the provider threshold **and** `route_to_orchestrator` is enabled.
+| Setting | Effect |
+| --- | --- |
+| `enabled` | When off, that provider's notifications are not ingested at all. |
+| `importance_threshold` | Minimum score (0.0 to 1.0) to display. `0.0` shows everything. |
+| `route_to_orchestrator` | When on, high-importance (`react` or `escalate`) items are forwarded to the agent. |
-These per-provider settings have no UI today: the page that edited them was removed, so they are set through the RPC or by hand. The per-category preferences gate **ingest**, not just display, which is worth knowing before changing one.
+Auto-routing re-reads the provider's settings just before it escalates, so a change takes effect immediately. A notification goes to the agent only when its score clears the provider threshold and `route_to_orchestrator` is on.
----
+These per-provider settings have no UI today. Set them through the RPC or by hand. They gate ingest, not just display, so keep that in mind before changing one.
## The notice tray
-Separate from the notification center, a quiet tray in the bottom-right corner collects **things you can act on**: a provider key that was rejected, a plan limit reached, a keyring consent prompt. It replaced the full-width banners that used to push the chat down. Repeats of the same problem bump a count rather than stacking, and the tray is in-memory, so it clears on restart.
+A quiet tray in the bottom-right corner collects things you can act on: a rejected provider key, a reached plan limit, a keyring consent prompt. Repeats of the same problem bump a count instead of stacking. The tray lives in memory, so it clears on restart.
-Product announcements arrive separately again, as a modal shown once per signed-in session, with the ids you have already seen remembered.
+Product announcements arrive separately, as a modal shown once per signed-in session. OpenHuman remembers the ids you have already seen.
----
-
-## Where background work surfaces
+## Where background work shows up
| Kind of background work | Where to look |
| --- | --- |
-| Scheduled jobs and their run history | **Workflows → Schedules**. See [Cron & Scheduling](native-tools/cron.md). |
+| Scheduled jobs and their run history | **Workflows → Schedules**. See [Cron and scheduling](native-tools/cron.md). |
| Workflow runs | **Workflows → Runs** |
| Memory belief builds and source syncs | **Connections → Memory → Background** |
| Detached sub-agents and async delegation | The background inbox card in the thread that started them. See [Chat](chat.md). |
-| Everything above, as notifications | The Notifications page, Agents category |
-
----
+| All of the above, as notifications | The Notifications page, Agents category |
## See also
-- [Cron & Scheduling](native-tools/cron.md): the scheduling engine and the agent tools behind the Schedules view.
+- [Cron and scheduling](native-tools/cron.md): the scheduling engine and the agent tools behind the Schedules view.
- [Triggers](integrations/triggers.md): webhooks and inbound events that can raise a notification.
- [Chat](chat.md): where an approval or a sub-agent result lands when you are in the conversation.
diff --git a/gitbooks/features/orchestration.md b/gitbooks/features/orchestration.md
index 502c3dff4a..0bdc1982cb 100644
--- a/gitbooks/features/orchestration.md
+++ b/gitbooks/features/orchestration.md
@@ -1,54 +1,57 @@
---
description: >-
OpenHuman is an orchestrator, not a chatbot: durable agent graphs, visual
- workflows, sub-agent fleets, and a split-brain always-on layer, all in one
- coherent stack.
+ workflows, sub-agent fleets and an always-on two-agent layer.
icon: sitemap
---
-# The Orchestrator
+# The orchestrator
<figure><img src="../.gitbook/assets/orchestration.png" alt=""><figcaption><p>OpenHuman orchestrating a fleet of agents.</p></figcaption></figure>
-Most harnesses run one agent in one loop. OpenHuman is built as an **orchestrator**: a stack for coordinating many agents, over long horizons, across machines. It does this durably, observably, and under your control.
-
-Four layers make that real:
+Most harnesses run one agent in one loop. OpenHuman coordinates many agents over long stretches of time, across machines. It does this durably, visibly and under your control. Four layers make that work.
## 1. Graphs, not loops
-Every agent turn runs on [tinyagents](https://github.com/tinyhumansai/tinyagents), our open-source graph engine. Multi-step work compiles to **state-machine graphs with conditional routing**: `plan → execute ⇄ review → finalize` for delegation, phase DAGs for multi-agent workflow runs, and map-reduce fan-out for parallel workers. All of it has **durable checkpointing**. A graph can pause mid-run (for your answer, for an approval, for a restart) and resume exactly where it stopped.
+Every agent turn runs on [tinyagents](https://github.com/tinyhumansai/tinyagents), our open-source graph engine. Multi-step work compiles to state-machine graphs with conditional routing:
-## 2. Sub-agent fleets that don't get lost
+- `plan → execute ⇄ review → finalize` for delegation.
+- Phase DAGs for multi-agent workflow runs.
+- Map-reduce fan-out for parallel workers.
-The orchestrator spawns specialized sub-agents (up to 3 levels deep), reuses compatible idle workers instead of re-spawning, and routes each to the right model tier: heavy reasoning for the core, a fast **burst tier** for low-context workers. Reliability is structural: a no-progress circuit breaker stops loops, and stuck children hand back a `question` (pause + resume on your answer) or an `Incomplete` root-cause summary, never silence. See the [Agent Harness](../developing/architecture/agent-harness.md).
+All of it is checkpointed. A graph can pause mid-run, for your answer, an approval or a restart, and resume exactly where it stopped.
-## 3. Workflows you can see
+## 2. Sub-agent fleets that do not get lost
+
+The orchestrator spawns specialized sub-agents, up to 3 levels deep. It reuses compatible idle workers instead of spawning new ones. It also routes each worker to the right model tier: heavy reasoning for the core, and a fast burst tier for low-context workers.
-[Workflows](workflows.md) lift orchestration out of the chat: the agent _proposes_ a typed graph of triggers, agents, tools and conditions; you review it on a canvas and save it. Runs are durable, approval-gated, and fully inspectable step-by-step, powered by open-source [tinyflows](https://github.com/tinyhumansai/tinyflows).
+Reliability is built in. A no-progress circuit breaker stops loops. A stuck child hands back a `question` (pause and resume on your answer) or an `Incomplete` root-cause summary, never silence. See the [agent harness](../developing/architecture/agent-harness.md).
-## 4. An always-on split brain
+## 3. Workflows you can see
-Inbound traffic hits a **fast reflex agent** that triages in seconds and hands a deep **reasoning core** a concise brief; the core does the multi-step work and delegates to workers. Mid-task steering input can be delivered into a live session, and 20:1 compression keeps week-long sessions bounded.
+[Workflows](workflows.md) move orchestration out of the chat. The agent proposes a typed graph of triggers, agents, tools and conditions. You review it on a canvas and save it. Runs are durable, gated by approvals and inspectable step by step. They run on the open-source [tinyflows](https://github.com/tinyhumansai/tinyflows) engine.
-## What's next
+## 4. An always-on two-agent layer
-The scripted-orchestration idea this page used to advertise, agents writing control flow as small programs in a sandboxed REPL, is **not being built**: the harness dropped that runtime and the tool no longer exists. The substrate above, graphs with checkpointing under a trust model, is the shape orchestration takes.
+Inbound traffic first reaches a fast reflex agent that triages in seconds. It hands a concise brief to a deeper reasoning core, which does the multi-step work and delegates to workers. You can steer a task mid-run, because input can be delivered into a live session. 20:1 compression keeps week-long sessions bounded.
-What is tracked in the open instead: an [agent-to-agent protocol](https://github.com/tinyhumansai/openhuman/issues/3463) so a graph can span instances, and durable swarm task graphs. See the [roadmap](../overview/roadmap.md).
+## What is next
----
+Agents writing control flow as small programs in a sandboxed REPL is not being built. The harness dropped that runtime and the tool no longer exists. Graphs with checkpointing under a trust model are the shape orchestration takes.
+
+Two items are on the [roadmap](../overview/roadmap.md): an agent-to-agent protocol so a graph can span instances, and durable swarm task graphs.
-## Why this differentiates
+## How it differs
-| | Single-agent harnesses (Claude Code, OpenClaw, Hermes) | OpenHuman |
-| --------------- | ------------------------------------------------------ | --------------------------------------------------------------- |
-| Execution model | One loop, one context | Compiled graphs, conditional routing, checkpoint/resume |
-| Parallelism | Manual / plugin | Native sub-agent fleets, map-reduce fan-out, worker reuse |
-| Automation | Scripts & cron | Visual, durable, approval-gated workflows |
-| Always-on | None | Split-brain reflex + reasoning core, mid-task steering |
+| | Single-agent harnesses (Claude Code, OpenClaw, Hermes) | OpenHuman |
+| --- | --- | --- |
+| Execution model | One loop, one context | Compiled graphs, conditional routing, checkpoint and resume |
+| Parallelism | Manual or plugin | Native sub-agent fleets, map-reduce fan-out, worker reuse |
+| Automation | Scripts and cron | Visual, durable, approval-gated workflows |
+| Always-on | None | Reflex agent plus reasoning core, mid-task steering |
## See also
- [Workflows](workflows.md)
-- [Agent Harness](../developing/architecture/agent-harness.md): the developer deep-dive on graphs, breakers, journals.
-- [Agent Coordination tools](native-tools/agent-coordination.md): the user-facing spawn/delegate surface.
+- [Agent harness](../developing/architecture/agent-harness.md): the developer deep dive on graphs, breakers and journals.
+- [Agent coordination tools](native-tools/agent-coordination.md): the spawn and delegate surface.