The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
docs: update integration and media READMEs for host-supplied backends
Steven Enamakel21a51f89a384
diff --git a/crates/openhuman-core/src/integrations/composio/README.md b/crates/openhuman-core/src/integrations/composio/README.mdindex c5baf7247e..370432d763 100644--- a/crates/openhuman-core/src/integrations/composio/README.md+++ b/crates/openhuman-core/src/integrations/composio/README.md@@ -152,7 +152,7 @@ Published from `ops/` via `crate::core::bus::BUS.publish` (`crate::core::events:## Dependencies-- `crate::integrations`: shared `IntegrationClient` (Bearer JWT, timeouts, envelope parsing, proxy) backing backend-mode calls.+- Backend mode is a route a host registers (`register_composio_route_builder` plus `modules::connectors::register_proxy_target`); the shared `IntegrationClient` that backs it lives in `openhuman-tinyhumans`.- `crate::config`: `Config` / `ComposioConfig` (`mode`, `entity_id`), `config::rpc` config loading.- `crate::modules`: loads the `tinyconnectors` native module that `module_client.rs` calls into (behind the `modules` feature).- `tinyconnectors_bus`: the wire contract (member names, payload types) for the `tinyconnectors` module call surface; a plain dependency, not feature-gated.diff --git a/crates/openhuman-core/src/media/README.md b/crates/openhuman-core/src/media/README.mdindex 03191a63cc..5465736590 100644--- a/crates/openhuman-core/src/media/README.md+++ b/crates/openhuman-core/src/media/README.md@@ -2,9 +2,10 @@Family root for media agent tools. Today it has one member,[`generation`](generation/README.md), which gives the agent image and video-generation through OpenRouter, proxied by the TinyHumans backend. The family+generation over generators a host supplies (the TinyHumans one is in+`openhuman-tinyhumans`). The familyis tools-only: there is no RPC controller, no store, and no bus subscriber.-The tool registry in `tools/ops.rs` is the only caller.+A host's tool source is the only caller of the tool builder.## How it worksdiff --git a/crates/openhuman-core/src/media/generation/README.md b/crates/openhuman-core/src/media/generation/README.mdindex 6ce6646b4f..4a390c49da 100644--- a/crates/openhuman-core/src/media/generation/README.md+++ b/crates/openhuman-core/src/media/generation/README.md@@ -1,8 +1,9 @@# generation-Image and video generation agent tools, backed by OpenRouter through the-OpenHuman backend's `/agent-integrations/openrouter` proxy. The work is-split across three layers, each with a different owner:+Image and video generation agent tools over generators a host supplies. The+TinyHumans host builds OpenRouter generators behind its backend proxy+(`openhuman-tinyhumans`, `integrations/media`). The work is split across three+layers, each with a different owner:- **TinyInference** (`tinyinference-image` / `tinyinference-video`, reachedthrough `tinyagents_harness`) owns the wire contract, the reference and@@ -12,19 +13,20 @@ split across three layers, each with a different owner:- **TinyAgents** (`tinyagents_harness::media`) owns the tools themselves:argument parsing, artifact persistence into the workspace, and resultwording.-- **This module** owns the host policy: endpoint, credential, egress,- privacy, and budget gates ([`provider.rs`](./provider.rs)), plus the tool names,- descriptions, and local-reference policy ([`tools.rs`](./tools.rs)).+- **This module** owns the `MediaGenerators` pair ([`provider.rs`](./provider.rs)),+ plus the tool names, descriptions, and local-reference policy+ ([`tools.rs`](./tools.rs)). Endpoint, credential, egress, privacy and budget+ gates belong to the host that builds the generators.## Key files| File | Role || --- | --- |-| [`provider.rs`](./provider.rs) | `managed_generators`: builds `MediaGenerators { image, video }` against the managed backend, or returns `None` when no backend transport is installed. Wraps each generator in a `Guard` that enforces local-only privacy mode and the egress disclosure before a request leaves the device, and the managed-credit budget gate before a billed submit. |-| [`tools.rs`](./tools.rs) | `build_media_tools`: registers `media_generate_image`, `media_generate_video`, and `media_list_models` as `Tool` implementations over the generators from `provider.rs`. Also defines `reference_policy`, which restricts local reference files (for image edits or video first/last frames) to the action directory or workspace directory. |+| [`provider.rs`](./provider.rs) | `MediaGenerators { image, video }` and `GeneratorRouter`: the pair the tools run over, with an optional router that rebuilds them around a turn's chat so egress disclosures reach it. The core ships no generators. |+| [`tools.rs`](./tools.rs) | `media_tools_for_config`: registers `media_generate_image`, `media_generate_video`, and `media_list_models` as `Tool` implementations over host-supplied generators. Also defines `reference_policy`, which restricts local reference files (for image edits or video first/last frames) to the action directory or workspace directory. || [`artifact_tool.rs`](./artifact_tool.rs) | `MediaArtifactTool`: wraps a generation tool so every file it saves is also tracked as an OpenHuman artifact, following the same `create_artifact` / `finalize_artifact` pattern the document and presentation tools use. Runs the inner tool unchanged, then files each reported output and stamps an `artifact_id` (or `artifact_error`) onto its entry. || [`progress.rs`](./progress.rs) | Progress for a long generation call: a heartbeat every 15s through `ToolRunContext::report_progress` while the inner tool runs, carrying the video job state the `WaitPolicy::progress` observer records on each poll. The harness emits these as `AgentEvent::ToolProgressDetail`, which the host publishes on the web channel as `tool_progress`; the chat UI does not render it yet. |-| [`mod.rs`](./mod.rs) | Re-exports: `MediaArtifactTool`, `managed_generators`, `MediaGenerators`, `OPENROUTER_PROXY_PATH`, `build_media_tools`, `media_tools_from`, `MediaListModelsTool`, and the three tool-name constants. |+| [`mod.rs`](./mod.rs) | Re-exports: `MediaArtifactTool`, `MediaGenerators`, `GeneratorRouter`, `media_tools_for_config`, `media_tools_from`, `MediaReferenceAllowlist`, `MediaListModelsTool`, and the three tool-name constants. |## Key typesdiff --git a/crates/openhuman-core/src/web3/README.md b/crates/openhuman-core/src/web3/README.mdindex 76746cf30f..65b4e5fc99 100644--- a/crates/openhuman-core/src/web3/README.md+++ b/crates/openhuman-core/src/web3/README.md@@ -41,8 +41,10 @@ response values, without deriving chains, rebuilding transactions, or signingon the host. Execution requires `confirmed: true`; the module validates quoteownership and gives the host the exact intent for approval at the signer seam.-The backend deBridge proxy remains a generic authenticated host transport at-`/agent-integrations/crypto/*`. Provider response parsing, chain-family+The backend deBridge proxy is reached through the wallet-backend hook+(`modules::wallet_backend`); `openhuman-tinyhumans` answers it over+`/agent-integrations/crypto/*`, and a core with none registered answers+`BACKEND_UNAVAILABLE:`. Provider response parsing, chain-familyselection, quote construction, transaction encoding, and quote storage aremodule-owned. Provider-specific URLs and defaults stay in the module; the hostpasses only approved endpoint overrides through opaque endpoint references.diff --git a/crates/openhuman-tinyhumans/src/integrations/client/README.md b/crates/openhuman-tinyhumans/src/integrations/client/README.mdindex 1138f6fc11..2ed7b67467 100644--- a/crates/openhuman-tinyhumans/src/integrations/client/README.md+++ b/crates/openhuman-tinyhumans/src/integrations/client/README.md@@ -1,8 +1,8 @@# client`IntegrationClient`: the shared HTTP client every integration domain uses to-talk to the OpenHuman backend's `/agent-integrations/*` routes. Composio,-task sources, and file storage all build one of these rather than making+talk to the OpenHuman backend's `/agent-integrations/*` routes. The managed+tools, file storage, media and web3 all build one of these rather than makingtheir own backend calls, so auth, egress policy, error classification, andbudget gating live in one place instead of being copied per domain.@@ -13,14 +13,14 @@ budget gating live in one place instead of being copied per domain.| [`construct.rs`](./construct.rs) | The `IntegrationClient` type and its constructors. Holds the backend URL, the app-session auth token, a separate `reqwest::Client` for downloads, and a lazily-fetched pricing cache. Also sanitizes a misconfigured `backend_url` that carries an inference-style path (issue #2075). || [`requests.rs`](./requests.rs) | Outbound request plumbing: route guards (refusing intentionally unexposed routes such as `webhooks`/`admin`), egress disclosure and enforcement, budget gating, and the JSON verb methods (`post`/`get`/`patch`/`delete`/`upload_multipart`). || [`download.rs`](./download.rs) | Raw-bytes download support. The file-storage download route 302-redirects to a presigned S3 URL; `get_bytes` reads `Content-Type` and `Content-Disposition` off the response since the JSON envelope helpers do not carry them. |-| [`budget_gate.rs`](./budget_gate.rs) | Refuses `/agent-integrations/*` calls once the account's AI credits are exhausted, so a tool call never burns a backend round trip the backend would reject anyway. Reads `GET /teams/me/usage` through `BackendOAuthClient` with a one-minute failure backoff to avoid flooding Sentry on a persistent outage. |+| [`budget_gate.rs`](./budget_gate.rs) | Refuses `/agent-integrations/*` calls once the account's AI credits are exhausted, so a tool call never burns a backend round trip the backend would reject anyway. Reads `GET /teams/me/usage` through `crate::client::BackendClient` with a one-minute failure backoff to avoid flooding Sentry on a persistent outage. || [`pricing.rs`](./pricing.rs) | The pricing cache on `IntegrationClient` plus `pricing_for_config`, which short-circuits to empty pricing in Composio direct mode (no backend session exists to serve `/agent-integrations/pricing` there). || [`errors.rs`](./errors.rs) | Backend error classification: extracting a readable detail from an error body, and handling the session-JWT 401 to session-expiry recovery path. |## How auth worksEvery request carries the app-session JWT as its `Authorization: Bearer`,-resolved through `crate::api::jwt::get_session_token`, the same token+resolved through `resolve_backend_credential`, the same credentialbilling, team, webhooks, and memory all use. A `401` from an`/agent-integrations/*` route is therefore unambiguous: it means that JWThas expired, been revoked, or been rotated server-side, never a@@ -29,23 +29,20 @@ session-expiry recovery.## How it fits-JSON traffic rides the process-wide `BackendTransport`-(`crate::api::transport`); `IntegrationClient` does not open its own-connections for anything but downloads. Domain code (`integrations::composio`,-`integrations::task_sources`, `integrations::file_storage`) builds one client-per call site through `crate::integrations::build_client` and calls its verb-methods directly rather than reaching for `BackendOAuthClient` or a raw-`reqwest` call.+JSON traffic rides `crate::client::IntegrationsHttp` over the shared SDK+transport; `IntegrationClient` does not open its own connections for anything+but downloads (which share `IntegrationsHttp`'s two clients). Domain code+(`file_storage`, `tools`, `media`, `web3`, `composio`) builds one client per call+site through `crate::integrations::build_client` and calls its verb methods+directly rather than reaching for `BackendClient` or a raw `reqwest` call.## Where to look nextSee [`../README.md`](../README.md) for the integrations domain overview.-`errors.rs`'s private `map_transport_error` is where a raw-`BackendTransportError` becomes the `anyhow::Error` every verb method-returns; `IntegrationClient::map_transport_error` in `AGENTS.md` refers to-this function.+`errors.rs`'s `map_transport_error` is where a raw `BackendTransportError`+becomes the `anyhow::Error` every verb method returns.## Further reading-- [Third-party integrations](../../../../../docs/gitbooks/en/features/integrations/README.md)-- [Connections](../../../../../docs/gitbooks/en/features/connections.md)+- [Third-party integrations](../../../../../../docs/gitbooks/en/features/integrations/README.md)+- [Connections](../../../../../../docs/gitbooks/en/features/connections.md)