Chat settings and web search

Engineering contract for session-local controls, durable message settings, and bounded search aggregation. Scope: the confirmed chat/search defects and the two verification failures. No change to Agent authority, approval rules, or network policy.

State and request ownership

Composer scope
Session settings and callbacks

Persisted draft
Profile, tools and search intent

Accepted message
SessionRunConfig and permissions

Execution
Available tools and provider results

BoundaryRequired behaviorAcceptance
Session controlsTools and Search mutate only their current scope. Tool profile uses the existing persisted settings map.Switch A → B → A; remount and split scopes preserve independent values.
SandboxCorrelate reads and writes by request ID; ignore superseded replies, abort listeners on scope changes, and report failed writes without optimistic state drift.Two opposite writes, stale reads, disconnect, and provisional session reads cannot overwrite the current selection.
Search intentExplicit off removes web_search. On adds it within existing Agent policy; mode none remains authoritative. Omitted intent preserves compatibility.Resolve tools for on/off/omitted and Agent none configurations.
Provider configurationShow a default only after confirmed save; require a Jina key. Unavailable saved defaults use another available provider. Stable schema accepts newly configured providers without restart.HTTP failure keeps old default; no-key and hot-key tests.
AggregationRace returns the first nonempty success. RRF preserves timely partial results. All failures and deadlines without successful responses are errors. Running sync requests finish under their transport deadlines; queued work is cancelled.Event-controlled providers verify early return, partial timeout, empty success, total failure, and cleanup.
Connection testSynchronous provider work runs off the server event loop.An async response can progress while the provider probe is blocked.

Evidence and alternatives

React callback dependencies require reactive setter dependencies. Reuse the existing session stores; do not remount the whole composer to conceal stale callbacks.

Python executor lifecycle explains why context-manager shutdown waits. Explicit non-waiting shutdown permits early return but cannot cancel already running sync requests. Preserve transport deadlines rather than introducing a new async provider API.

Jina search requires authenticated access in the tested endpoint. Availability must reflect credentials rather than unconditional success. Registration uses stable provider names; runtime availability is checked for each call.

Regression checks use the production hooks, socket request helper, tool executor and resolver. Product docs describe explicit search off and per-session profile persistence. Existing verification failures use URL-safe filesystem conversion and regenerated package READMEs.

Provider schema visibility

Explicit Web Search intent ships its schema in the provider request, including search-only chats. Promotion copies the selected tool and preserves the shared deferred registry and Agent exclusions. Cold-session and frozen-turn regression checks cover the provider split.

Implementation status

Implemented and independently reviewed. Regression tests cover session switching, profile restoration, correlated Sandbox replies, failed provider saves, explicit search policy, provider availability, early aggregation return and partial failures. Python, Web, browser, desktop and documentation verification pass. Explicitly enabled search schemas are included in provider requests. Independent specification and quality reviews pass; cold-session and frozen-turn regression checks verify schema visibility. Automated and default-App acceptance evidence is maintained in the task ledger.