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 READMEs to reflect vendored tinyinference path and module structure
Steven Enamakelac3438e40b2d
diff --git a/crates/openhuman-core/src/agent/prompts/README.md b/crates/openhuman-core/src/agent/prompts/README.mdindex 792204cc75..3476f750e3 100644--- a/crates/openhuman-core/src/agent/prompts/README.md+++ b/crates/openhuman-core/src/agent/prompts/README.md@@ -57,8 +57,9 @@ as `GLOBAL_STYLE_SUFFIX`. Two uses:user edit survives until the next release that touches that asset. Onlyabsolute `workspace_dir`s are seeded. `IdentitySection` syncs`SOUL.md`/`IDENTITY.md`/`ROLE.md` (`ROLE.md` is injected only when- `visible_tool_names` is non-empty, i.e. for the orchestrator); `builder.rs` syncs `STYLE.md` on every build so agents that- set `omit_identity` still get the style rules.+ `visible_tool_names` is non-empty, i.e. for the orchestrator); `builder.rs`+ syncs `STYLE.md` on every build so agents that set `omit_identity` still get+ the style rules.- **Compile-time fallback** — `GLOBAL_STYLE_SUFFIX` is used when theworkspace `STYLE.md` cannot be read.@@ -84,14 +85,14 @@ Other domains contribute prompt content without living in this directory:- `agent/learning/prompt_sections.rs` — `LearnedContextSection`,`UserProfileSection`, `MemoryAccessSection`, `MemoryWriteSection`- (`PromptSection` impls, config-gated; `session/builder/factory.rs` and- `session/builder/helpers.rs` append them with `add_section` /+ (`PromptSection` impls, config-gated; `agent/harness/session/builder/factory.rs`+ and `.../builder/helpers.rs` append them with `add_section` /`insert_section_before` when learning or explicit preferences are enabled).- `agent/profiles/prompt_section.rs` — `AgentProfilePromptSection`, the`## Agent profile` persona body plus the optional cross-profile workspace- notice; added by `session/builder/factory.rs`.+ notice; added by `agent/harness/session/builder/factory.rs`.- `tools/agent_policy/prompt.rs` — `render_tool_policy_boundary` is not a- section: `session/turn/context.rs` string-appends its `## Tool Policy+ section: `agent/harness/session/turn/context.rs` string-appends its `## Tool PolicyBoundary` block after the builder output so the session-scoped bytes landat the tail of the prompt.@@ -99,7 +100,7 @@ Built-in archetype system prompts (orchestrator, welcome, integrations_agent,…) live in `agent/registry/agents/<name>/prompt.rs` and`flows/agents/{flow_discovery,workflow_builder}/prompt.rs`, not here. Each is a`PromptSource::Dynamic` function that hand-assembles its body via the-`render_*` helpers; `session/builder/factory.rs` wraps it with+`render_*` helpers; `agent/harness/session/builder/factory.rs` wraps it with`SystemPromptBuilder::from_dynamic`.## Builder entry pointsdiff --git a/crates/openhuman-core/src/inference/embeddings/README.md b/crates/openhuman-core/src/inference/embeddings/README.mdindex 0f19caddbf..15a886e277 100644--- a/crates/openhuman-core/src/inference/embeddings/README.md+++ b/crates/openhuman-core/src/inference/embeddings/README.md@@ -2,23 +2,31 @@Host policy and RPC surface for vector embeddings. Concrete OpenAI-compatible,Cohere, Voyage, Ollama, cloud-transport, retry, and rate-limit implementations-live in `tinyinference::embeddings`; this domain selects and adapts those-models for OpenHuman.+live in `tinyinference::embeddings` (vendored at+`vendor/tinyagents/vendor/tinyinference`); this domain selects and adapts+those models for OpenHuman.## Host-owned responsibilities- `factory.rs`: provider slug/model/dimension selection and construction of- TinyAgents models.-- `provider_trait.rs`: compatibility contract used by existing OpenHuman- consumers plus `TinyAgentsEmbeddingProvider`, the one trait adapter.-- `cloud_adapter.rs`: OpenHuman session-token resolution, egress disclosure,- and local-only privacy enforcement around TinyAgents `CloudEmbeddingModel`.+ `tinyinference` embedding models. Also owns `MODELS_SUPPORTING_DIMENSIONS`,+ the list of models allowed to request a non-default dimension.+- `provider_trait.rs`: re-exports the `EmbeddingProvider` contract and+ `format_embedding_signature` from `tinymemory_api::host`, and defines+ `TinyAgentsEmbeddingProvider`, the one adapter from a `tinyinference`+ `EmbeddingModel` to that contract.+- `cloud_adapter.rs` (module `cloud`): `OpenHumanCloudEmbedding`, which wraps+ `tinyinference`'s `CloudEmbeddingModel` with OpenHuman session-token+ resolution, egress disclosure, and local-only privacy enforcement.- `catalog.rs`, `rpc.rs`, `schemas.rs`: Settings catalog, credentials, JSON-RPC,connection tests, and re-embed/wipe policy.-- `noop.rs`: unit-struct compatibility adapter over TinyAgents' no-op model.+- `noop.rs`: re-export of `tinymemory_api::host::NoopEmbedding` so the host and+ the memory module share one type when embeddings are switched off.+- `rate_limit` and `retry_after` (in `mod.rs`): thin re-exports of the+ `tinyinference` limiter and 429 backoff helpers under their older names.-Provider HTTP behavior and its tests belong in `vendor/tinyagents`. Do not add-new per-provider clients here.+Provider HTTP behavior and its tests belong in `tinyinference`. Do not add new+per-provider clients here.The canonical embedding-space signature is`provider={name};model={model};dims={dims}`. Configuration-derived and live@@ -26,17 +34,22 @@ provider signatures must remain byte-identical or stored vectors split intoincompatible spaces.The separately compiled TinyMemory module reaches this factory through the-`EmbeddingHost` bus interface in `modules/memory_host.rs`, which resolves the-API key and calls `create_embedding_provider_with_config` per request; its-fixed on-disk dimension remains 1024 (see `memory/tree/health` mismatch-errors). Ollama requests use TinyAgents' `RECOMMENDED_OLLAMA_CONTEXT_TOKENS`-for both `num_ctx` and `num_batch`.+`EmbeddingHost` bus interface in `modules/memory_host.rs`, whose `embed`+method resolves the API key via `resolve_api_key` and calls+`create_embedding_provider_with_config` on every request. The module's tree+stores fixed 1024-dimension vectors (`EMBEDDING_DIM` in tinymemory-core's+`tree::score::embed`), so `modules::ops` hands it+`MODELS_SUPPORTING_DIMENSIONS` at load time and the module omits the+`dimensions` parameter for any model not on that list.## Wiring- Controllers are registered from `all_embeddings_registered_controllers()`,- called by `core/all.rs` alongside the other domain registrations.-- RPC handlers live in `schemas.rs` and dispatch through `rpc.rs`.+ pushed under `DomainGroup::Inference` in `core/all.rs`.+- `schemas.rs` declares the `embeddings` namespace functions (`get_settings`,+ `update_settings`, `set_api_key`, `clear_api_key`, `embed`,+ `test_connection`) and dispatches to the handlers in `rpc.rs`+ (`rpc_part_01.rs`, `rpc_part_02.rs`).- See `mod.rs` for the current provider set (Managed default via the backend's`POST /openai/v1/embeddings`, Voyage, OpenAI, Cohere, Ollama, Custom, Noop)and `tinyinference::embeddings` for their concrete implementations.