Remove the profile limits, runtime counters, quota errors, and extra-round resume flow. Keep tool authorization stateless and give protocol drift recovery its own 20-attempt limit, reset on resume.
Migrate profiles to schema 5 and discard retired fields at the existing profile, draft, and checkpoint decoding boundaries. Route shared Session profile migration and persistence through AgentProfileService.
Validation: pnpm run check; focused profile and runtime tests; macOS profile migration, JSON save, export dialog, and old checkpoint reads.
Use resource identity for thumbnail state and distinguish stale refs from unexpected errors. Append image diagnostics before deciding whether MCP results are empty, and reuse shared role, media and workspace helpers.
Use the capture filter's geometry consistently, share mobile plugin transport, and remove redundant state, error variants and test assertions. Update the API and architecture documentation to match.
Validation: pnpm run check; focused frontend, Gemini, MCP, image and byte-stream tests; Android debug APK build.
Store incoming images and rejection notes through one entry point, then project MCP results without duplicating structured text or describing image-only results as empty. Centralize stored image formats and file paths, reuse workspace text reads, and remove superseded identity checks.
Preserve Claude tool images and original text with or without current tool definitions. Route OpenAI-compatible tool media once and reject unsupported Gemini tool audio/video. Document capability, normalization and retention at their owning topics.
Validation: payload, gateway, runtime, MCP, image and Shell focused tests; Rust crate boundaries; pnpm run check.
Read tool image files through a bounded binary workspace API that shares path handling with text reads. Load thumbnails only while tool details are expanded, use the recorded MIME type, and release object URLs on unmount.
Validation: assistant UI tests 10/10 and Agent API contracts 28/28 passed; TypeScript, frontend guardrails, lint, crate boundary and diff checks passed. Shared Rust read path compiled with host MCP contracts.
Normalize extension tool images once into workspace files, keep only references in history, and hydrate a request copy before model retries. Carry the admitted image capability through invocation binding and Session compaction, count retained images, and encode tool images in each provider format. Consolidate tool result construction and redact inline media by structure.
Validation: extension runtime contracts 4/4; agent tools 18/18; tool results 5/5; provider image encoding 4/4; HTTP classification and log redaction focused tests; extension JS contracts 3/3; TypeScript, frontend guards, lint and crate boundaries passed.
Let idle Sessions compact through the existing runtime flow without adding a user message or requesting a reply. Publish runtime context measurements in Run events and show their share of the compaction point in the composer, with an action to compact immediately.
Share Session admission and observation between sending and compaction, retain observed runs that write no message, and update API contracts, translations and behavioral coverage.
Validation: pnpm run check.
Address Review-2. Admit a prompt snapshot once and carry the parsed request
forward; the host round trip builds its own scope. Active Runs report the seq
their activation starts after, so restored bridges skip a resumed Run's earlier
terminal event. Session prepare returns its assembly request directly, start
always records the generation intent, and one builder serves every assembly.
Count tool calls with the encoder's alias rule, pair the compaction trigger
with its count, and rename the limits errors after contextLimits. Classify only
the provider's error value, including the nested error of a Responses
WebSocket event. Claude reports every non-refusal stop. Drop frontend Session
counting, repeated guards and fallbacks on values that are always present, and
document each fact once at its owner.
Validation: pnpm run check (browser 78, contracts 429, UI, Rust, clippy).
Address Review-1 §2. Keep Session counting in Rust and pass each round's count
into compaction. Separate retained-group selection, summary generation and the
recording flow; reuse the decoded response text and avoid cloning Session state.
Group root invocation startup inputs and drop a redundant transport reset.
Build canonical snapshot metadata once as contextLimits. Share current-prompt
payload preparation while retaining the live extension event before conversion.
Localize the compaction row and use the application's locale and entry animation.
Validation: 43 host Agent contracts; frontend types; 28 API tests; 2 browser suites; 9 assistant UI tests; frontend guardrails/lint; crate boundaries.
Use preset token budgets and provider usage to compact Session context at the
point or once after a context overflow. Append the summary to canonical history,
retain whole recent groups, and rebuild through the frozen PromptManager request
before continuing the original round. Keep full history for macros and the UI.
Restore active Session assembly bridges from bootstrap after APP_READY, so page
reloads resume pending assembly and Web Host startup makes no native Session call.
Show compaction progress and a folded summary in the assistant transcript.
Validation: pnpm run check; focused Session/storage/provider tests; Web Host startup tests; real Gemini compaction on desktop, Android and iOS; desktop reload, prompt layout/macros, next-send context and context_full checks.
The assistant read a Run's start from a `run_started` event that the
backend never emits; it records `run_created`. The status strip therefore
never showed elapsed time, and the transcript fell back to the first
loaded message, which is late once a long run spans several pages.
Session run handles now carry the run record's `createdAt`. The status
strip and the current run's bar use it, and the controller keeps it for
the same run after the terminal refresh drops the handle. Runs that ended
before the page opened still use their loaded messages. The event journal
docs now name `run_created`.
Validation: pnpm run check; in-app-agent tests after the terminal-refresh
follow-up.
Sub-agents and handoff targets bound to the current chat preset skipped
PromptManager: they received only their instructions and the task, and
inherited the root's sampling, model and Skill scope. The run input was
also trimmed by the root profile before it was frozen, so their own
context policy could not apply.
Generate() now collects unprojected material before the live assembly
and seals it after the hooks (frozen input schemaVersion 2), keeping
World Info, examples and Author's Note additions by source. A single
projection applies each profile's history window and World Info choice;
the live root uses it too and writes its World Info injections back for
{{outlet}}. The World Info scan no longer rewrites the global Author's
Note; Generate() composes it.
Every delegated invocation now requests host assembly through one preset
resolver: the current preset comes from the capture, a named preset from
the repository. Only a root bound to the current preset reuses its live
generation. The run's preset Skill scope is the captured chat preset,
and legacy `none` bindings read as currentPromptSnapshot.
Fixes#328.
Validation: pnpm run check.
Capture Agent inputs after extension hooks and share MacroEnv across prompt and request templates. Remove frozen macro emulation while preserving live extension behavior.
Simplify live data reads and browser test discovery; document the public context APIs.
Validation: pnpm run check.
Return timeouts as tool errors so the model can inspect state and continue. Retain cooperative cancellation and warn that the operation may still be running.
Carry assistant text and reasoning through the shared live projection and persist session invocation/round identity for preview reconciliation. Update writing consumers and suppress in-flight event delivery after unsubscribe.
Register WebView tools through a dedicated provider with shared tool selection, naming, and result handling. Keep extension availability independent from saved profile selections.
Clarify model-facing feedback and consolidate behavioral tests and architecture documentation.
Add standalone sessions with a shared profile, continuous JSONL history, and persistent work/tmp directories. Reuse frontend preset assembly and the existing model/tool loop with explicit Chat and Session targets.
Validation: pnpm run check
Document skill mounts, prompt catalogs and migration boundaries. Retain the JavaScript capability and kit references while removing obsolete executor details.
Route /fix through the existing resume lifecycle and revise the last reply's selected swipe from its current saved text. Preserve manual edits, support command cancellation, and keep persistent metadata on the bound message.