Commit graph

605 commits

Author SHA1 Message Date
Alessandro
727a840e10 Keep WebUI browser frames on base64 fallback
Disable WebUI binary-frame negotiation until its Socket.IO client reconstructs frame attachments as real Blob, ArrayBuffer, or typed-array values.

Reject placeholder binary payloads instead of wrapping them into broken image blobs, preserving the slim-frame path through base64 frames.

Document the transport constraint and pin the fallback behavior in browser regression coverage.
2026-07-03 02:15:54 +02:00
Alessandro
91b3bc9613 Slim browser viewer frame transport
Negotiate binary and slim screencast frames so updated clients avoid base64-in-JSON and repeated viewer metadata on every frame.

Clamp screencast capture to the subscriber viewport and DPR, lower streaming JPEG quality while preserving snapshot quality, and teach the client to manage binary frame URLs safely.

Document the browser viewer performance plan and update regression coverage for the new transport contract.
2026-07-03 01:49:07 +02:00
Alessandro
686e039d1b Wait for Browser screencast frames
Replace the WebSocket viewer frame pump's idle poll with read_screencast_frame so live screencast delivery follows the producer cadence instead of a 50 ms sleep cycle.

Keep idle-page timeouts inside the stream loop to avoid screencast restart flashes, and update the Browser regression test to pin the blocking read path and timeout handling.
2026-07-03 01:25:56 +02:00
Alessandro
306012eb00 Default desktop text files to Writer
Set LibreOffice Writer as the Desktop MIME default for Markdown and plain text while keeping Agent Zero Editor as the secondary Open With association.

Update the Desktop DOX contract and extend the routing regression test to pin the Writer-first association order.
2026-07-03 01:08:02 +02:00
Alessandro
05481c222a Fix browser URL intent routing
Limit the Browser URL-intent handler to web URL schemes so custom Agent Zero schemes fall through to their owning surfaces.

Document the scheme-ownership contract and cover the a0-editor misroute regression in the desktop/editor routing test.
2026-07-03 01:07:49 +02:00
Alessandro
da505de50a fix: prevent stale OAuth model provider selection
Render the OAuth model provider select as unchosen when the stored model slot still points at a non-connected or non-OAuth provider. This avoids showing Codex/ChatGPT as selected while the model input remains disabled, keeping account-backed model selection explicit.
2026-07-02 17:29:40 +02:00
Alessandro
0a9e15be87 Disable What's New cards
Move active What's New content into an empty slide list so the startup modal stays quiet until new cards are added. Keep manual Open available with an empty state, and update the static test plus DOX contract for dormant periods.
2026-07-02 17:29:40 +02:00
Alessandro
bcdc99e6cc Clarify optional memory plugin docs
Remove memory-plugin assumptions from root and non-plugin DOX contracts so disabled plugins are not implied as available runtime behavior.

Keep the memory plugin documented only in its owning plugin subtree and mark it optional from the parent plugin index.
2026-07-02 17:29:40 +02:00
Alessandro
63d0536cdc Update default main model to Claude Sonnet 5
Set the bundled model config, Balance preset, and onboarding OpenRouter default to anthropic/claude-sonnet-5. Refresh the model config README example to match.
2026-07-02 17:29:40 +02:00
Alessandro
446031429d Refresh Codex OAuth model defaults
Stop seeding stale Codex OAuth model metadata so connected accounts use the upstream /models response instead of the retired gpt-5.2-codex default.

Use gpt-5.5 as the Codex proxy fallback model, omit the fake legacy client version when Codex CLI is unavailable, and remove the stale Copilot fallback entry.

Add focused OAuth regressions for the current default model, upstream model-list behavior, and Copilot fallback ordering.
2026-07-02 17:29:40 +02:00
Alessandro
caf5c2f129 Refine onboarding model setup flow
Remove composer blocking so sends always create or enter a chat and route missing-model messages through the in-thread gate.

Make Utility model selection explicit by removing same-as-main sync and defaulting to each provider's utility model when available.

Compact onboarding success channel cards and update static regressions for the new onboarding/gate behavior.
2026-07-02 17:29:40 +02:00
Alessandro
8d887e6f6d Unify onboarding provider selection
Replace the separate Cloud/Local illustrated path screen with a single provider step that switches between Cloud, Account, and Local choices.

Route the first-send gate account choice through onboarding, remove the old Cloud/Local card assets, and keep model setup in the existing onboarding flow.

Update static onboarding and welcome composer regressions for the merged provider step.
2026-07-02 17:29:40 +02:00
Alessandro
b75b0f2c5c Require explicit model choice after OAuth connect
Stop auto-populating Main and Utility models when an OAuth account is already connected or newly connected.

Add a connected-account gate state that routes users to model configuration instead of choosing provider defaults silently.

Update OAuth notifications, chat gate copy, DOX contracts, and focused static regressions for the explicit model-selection flow.
2026-07-02 17:29:40 +02:00
Alessandro
04ecaac0cd Add deferred first-send model gate
Move missing-model setup out of the welcome screen and into an in-thread gate that preserves the pending prompt, survives refresh, and auto-dispatches after a usable model is configured.

Reuse existing onboarding, OAuth account settings, and advanced model configuration surfaces instead of duplicating provider forms. Connected OAuth accounts can now populate Main and Utility defaults when no chat model is configured.

Update model readiness checks, focused static regressions, and DOX contracts for the new deferred setup flow.
2026-07-02 17:29:40 +02:00
Alessandro
b07d142938 Coerce memory load numeric args
Normalize memory_load threshold and limit values from model calls before vector search so numeric strings from Responses tool arguments do not reach FAISS unchanged.

Add a focused regression covering string threshold/limit values and document the memory plugin contract.
2026-07-02 17:29:40 +02:00
Alessandro
855694faf4 Add What's New plugin thumbnail
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Add the missing 256x256 thumbnail asset for the built-in What's New plugin. The image is compressed under 20 KB and stored in the plugin web UI asset location used by bundled plugin cards.
2026-06-24 13:21:28 +02:00
Alessandro Frau
e2a23aafe6
Merge pull request #1705 from TriTechAI/fix/git-pager-cpu-spin
Disable pagers in non-interactive code execution shells
2026-06-24 11:14:27 +02:00
Alessandro
a18a35977a Fix pytest capture import in TTY session
Guard stream reconfiguration so pytest capture objects without reconfigure support can import the code execution TTY helper while preserving UTF-8 error handling for normal streams.
2026-06-24 11:13:42 +02:00
TerminallyLazy
15aa7d71f0 feat: add tiny local tool-use profile 2026-06-24 03:59:21 -04:00
Alessandro
3fae1f49e7 Expose context window size in model settings
Move the ctx_length control for main and utility model slots above the Advanced disclosure while keeping embeddings excluded. Add a static regression guard so primary context controls stay visible outside Advanced.
2026-06-23 20:07:59 +02:00
Alessandro
f051d6580f Fix mobile compaction modal spacing
Reset inherited mobile white-space inside the chat compaction modal so template indentation does not render as large vertical gaps.

Constrain the custom dialog body and raise the overlay above the mobile canvas rail.
2026-06-23 19:58:06 +02:00
Alessandro
3106abce96 Preserve surface windows across refresh
Restore restorable surface modals through the initFw_end extension hook and keep right-canvas state in session storage for normal reloads.

Fix Desktop host visibility after modal cleanup so preserved iframes reattach to real modal or canvas hosts, and remove the duplicate file-browser path icon overlay.
2026-06-23 18:28:16 +02:00
Alessandro
5c5dc07f92 Clarify Gemini OAuth as Google Cloud
Rename the Gemini OAuth provider surface to Google Cloud Gemini so the OAuth provider list points users toward the required Google Cloud project setup.

Align model-provider metadata, usage-plan copy, README wording, and static assertions while keeping the Gemini API OAuth mechanics unchanged.
2026-06-23 17:30:11 +02:00
Alessandro
53ad7ba2dc Persist loaded skills through compaction
Store explicitly loaded skill IDs as chat-wide context data while keeping full skill bodies in normal tool-result history. Reattach any loaded skill body that is no longer visible after compaction by reimporting the current skill from its source, without revision hashes or protocol reinjection.

Update compaction and summary prompts to preserve loaded skill names only, refresh DOX contracts, and add focused coverage for context-data persistence, legacy agent-data migration, duplicate suppression, and post-compaction reattachment.
2026-06-23 16:32:21 +02:00
Alessandro
bd584da2f4 Improve Editor text file workflows
Generalize the Editor storage/session path from Markdown-only to exact-text .md and .txt documents, including open, save, Save As, and rename refresh behavior.

Expose Open in Editor as a visible row action in the File Browser for Editor-owned text files, keep non-Editor surface opens in the overflow menu, and route Desktop text MIME handling through the Editor bridge.

Tests: node --check webui/components/modals/file-browser/file-browser-store.js; python -m py_compile plugins/_office/helpers/document_store.py plugins/_editor/helpers/markdown_sessions.py plugins/_editor/api/editor_session.py plugins/_editor/api/ws_editor.py plugins/_desktop/helpers/desktop_session.py plugins/_desktop/api/desktop_session.py plugins/_office/api/office_session.py plugins/_office/api/ws_office.py; pytest tests/test_office_document_store.py tests/test_file_browser_navigation.py tests/test_office_canvas_setup.py -q
2026-06-23 14:42:49 +02:00
Alessandro
6ccd48e81f Group mobile browser toolbar controls
Move Annotate and Browser settings into the Browser toolbar so narrow views keep navigation and controls on one row above a full-width address bar.

Make the Browser panel itself the container-query boundary so mobile modals and narrow right-canvas panels share the same polished toolbar layout, with regression and DOX coverage.
2026-06-23 14:17:13 +02:00
Alessandro
0028473ec9 Polish mobile browser affordances
Keep the File Browser path and search affordances on compact mobile rows, with create buttons sharing the search row and the Up control sharing the path row.

Give the Web Browser mobile toolbar a full-width address row by moving navigation controls above it, and add regression/DOX coverage for the layout contracts.
2026-06-23 14:01:30 +02:00
Alessandro
82bb0b9292 Refine What's New update gating
Show the What's New modal once per newer version by default, add a browser-local permanent opt-out checkbox, and expose the modal through the builtin plugin Open action. Keep the legacy modal path as a compatibility redirect and update the local DOX/tests for the new contract.
2026-06-23 13:14:03 +02:00
Alessandro
ffddc3ebcb Promote Files into shared canvas surface
Add Files to the universal canvas rail and sidebar flow, with a reusable floating surface modal chrome that matches Browser/Desktop behavior.

Make the File Browser modal draggable/resizable with Focus mode, keep Editor on the same draggable modal helper, and preserve dock/undock handoff state.

Harden File Browser startup so empty paths resolve to the default workdir, restyle the Up control, compact New file/New folder actions, and hide Modified before Name/Size in narrow containers.

Update DOX contracts and focused regression coverage for the new Files surface, modal chrome, default-path fallback, and compact layout behavior.
2026-06-23 11:19:58 +02:00
Alessandro
51f3ed00a1 Add project extension data hooks
Introduce generic project edit-data extension hooks so plugins can contribute named project settings sections without coupling helpers.projects to plugin-specific storage.

Move _model_config project LLM payload handling behind those hooks and preserve inherited global model settings unless a project override already exists or is explicitly selected.

Cover the inheritance regression, existing scoped overrides, multiple plugin sections, core-field collision protection, and extension payload filtering in focused project/model-config tests.
2026-06-23 07:34:21 +02:00
Alessandro
489acfe8c6 Refine welcome screen setup surfaces
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Fold the blocking onboarding state into the welcome composer, refresh the account and channel tiles, and keep system resources aligned with the renewed Welcome Screen layout.

Update model-config, OAuth, and welcome static tests to pin the new CTA, dismissal, copy, and layout contracts.
2026-06-23 02:21:44 +02:00
Alessandro
0e262f7b87 Refresh welcome screen and composer
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Rework the welcome screen around the shared new-chat composer, renewed quick actions, discovery cards, OAuth accounts, and dedicated system resources panel.

Restore static button colors and neutral surfaces, move microphone state feedback onto the icon, and keep Rubik/code-font composer behavior.

Add focused static regressions for the welcome composer, OAuth discovery panel, and speech button contract.
2026-06-22 15:12:20 +02:00
Alessandro
2a81e37499 Add built-in What's New showcase plugin
Introduce an always-enabled _whats_new plugin that shows a version-gated feature showcase modal with bundled media assets for parallel tool calls, the redesigned MCP configuration UI, and Skills Scanner.

Track the plugin in DOX and add static coverage for the modal copy, assets, manifest, and startup trigger.
2026-06-19 17:26:29 +02:00
Alessandro
98e51fbb2a Fix compaction backups for malformed Unicode
Some checks failed
Build And Publish Docker Images / plan (push) Has been cancelled
Build And Publish Docker Images / build (push) Has been cancelled
Use the shared sanitized file writer for chat compaction backup artifacts so JSON and transcript backups remain writable when a long chat contains malformed Unicode such as lone surrogates.

Add a regression that exercises surrogate-containing backup content and document the backup artifact contract in the chat compaction DOX file.

Verified with: conda run -n a0 pytest tests/test_chat_compaction.py -q; python -m py_compile plugins/_chat_compaction/helpers/compactor.py tests/test_chat_compaction.py; live localhost:32080 surrogate-long-chat repro after syncing into /a0 and restarting the container.
2026-06-19 14:33:36 +02:00
Alessandro
77552b9394 Refine document query image routing
Prefer vision_load for images, screenshots, scans, charts, photos, and diagrams when vision tools are available.

Keep document_query focused on PDFs, documents, large text-heavy files, code-file Q&A, and fallback OCR when vision cannot read the needed text.

Update bundled prompt, skill guidance, DOX notes, and regression coverage for the routing contract.
2026-06-19 01:49:50 +02:00
frdel
afdc3aeb44 Add protocol prompt area before history
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Introduce a new prompt "protocol" separate from extras: add LoopData.protocol_temporary and protocol_persistent, include protocol contents before message history during prompt construction, and clear temporary protocol data each turn. Add helper _build_context_message to render protocol/extras, update response input conversion to include protocol, and move project instructions & active/loaded skills injection into protocol. Update docs, prompts, plugin metadata, the SkillsTool message, and add tests to verify protocol placement and behavior.
2026-06-18 21:42:06 +02:00
Alessandro
bf2741990a Revert loaded skill history persistence
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Reverts db01d7c1c8 and 3c83b2eca2.

Restores the prior loaded-skills prompt-extras behavior and removes the compaction reattachment metadata path.
2026-06-18 16:45:56 +02:00
Alessandro
d398656d33 Make Browser viewer CDP-live by default
Default the WebUI Browser surface back to live CDP screencast while keeping snapshot/state transport as a fallback. Carry viewer transport through the WebSocket API and Browser store, use screencast metadata to avoid extra frame dimension decode, and include frame-chain action metadata in Browser content results. Update Browser prompts, skill guidance, DOX, and focused regressions so agent actions prefer DOM/CDP refs while the visible Browser remains responsive.
2026-06-17 16:15:07 +02:00
Alessandro
b9153f718e Preserve subordinate agent profiles
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Validate call_subordinate profile arguments against available agent profiles so missing profiles fail as repairable errors. Persist each agent's profile in saved chats and avoid flattening existing subordinate profiles during profile switches, settings refresh, or restart reload.
2026-06-17 13:07:22 +02:00
Alessandro
630bfc16f2 Repair sentence-transformer embedding config aliases
Patch stale sentence-transformer embedding provider/model aliases at the _model_config read/build boundary so memory embeddings use the intended local HuggingFace provider without adding provider-specific logic to models.py.

Cover stale alias forms, the bare default alias, normal OpenAI embedding pass-through, and missing API-key detection with focused regression tests.
2026-06-17 02:53:07 +02:00
Alessandro
3c83b2eca2 Reattach loaded skills after compaction
When compression hides an explicitly loaded skill body, reattach the current missing revision as a normal skills_tool history result under one fixed budget. Preserve skill name and revision metadata in automatic and manual compaction summaries without copying full skill bodies.
2026-06-16 14:31:37 +02:00
Alessandro
2615fb8e3f Reassemble chunked connector file results
Buffer JSON/base64 connector_file_op_result chunks per pending file operation and resolve only after the complete result is assembled.

Validate malformed chunk metadata with a pending-operation error, while preserving the existing single-payload behavior for small file operations.
2026-06-16 13:59:38 +02:00
Alessandro
ec3c4cf81b Add browser skill discovery triggers
Add trigger frontmatter for browser automation and browser form workflow skills so relevant-skill recall surfaces them for rendered browsing, screenshots, host-browser, and form-heavy tasks. Update build-skill guidance to document trigger metadata and add regression coverage for parsing and ranking the browser skills.
2026-06-16 13:19:17 +02:00
Alessandro
9bcef39028 Add llama.cpp and vLLM local providers
Add llama.cpp / llama-server support:
- Register llama.cpp chat and embedding providers through hosted_vllm defaults on host.docker.internal:8080.
- Add onboarding metadata, a bundled icon, no-key provider metadata, model discovery coverage, setup docs, and tests.

Add vLLM support:
- Register vLLM chat and embedding providers through hosted_vllm defaults on host.docker.internal:8000.
- Add onboarding metadata, a bundled icon, no-key provider metadata, model discovery coverage, setup docs, and tests.
- Strip empty tools arrays from the Responses-to-chat fallback path so strict OpenAI-compatible servers accept local vLLM calls.
2026-06-15 05:37:28 +02:00
Alessandro
0450098117 Add oMLX local provider support
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Add oMLX as a first-class local chat and embedding provider using the Docker-friendly host.docker.internal:8000/v1 default and LiteLLM hosted_vllm wiring. Mark it as a no-key local provider, include it in onboarding with a bundled logo, document Apple Silicon setup including paged SSD cache, and cover the provider defaults, model search behavior, and onboarding metadata with focused tests.
2026-06-15 04:54:52 +02:00
Alessandro
c56b65803b Slim browser prompt with progressive skills
Keep the browser tool prompt as a compact callable contract and move detailed workflows into browser-automation, with fragile form guidance chained through browser-form-workflows. Add regression coverage for the skills_tool loading path, host browser setup hint, and prompt token ceiling.
2026-06-15 03:23:09 +02:00
shisan
528c33b7ef Disable pagers in non-interactive code execution shells
The code execution tool runs commands inside TTY-backed shells (local PTY and
remote SSH). Commands like `git diff`/`git log` detect the TTY and pipe output
through a pager (more/less). These shells never receive interactive input, so
the pager blocks forever and spins at 100% CPU per process — on a 16-core host
5 pager processes pegged 5 cores for 8+ hours (#1697).

Disable pagers in both session types:
- LocalInteractiveSession: inject PAGER=cat / GIT_PAGER=cat into the TTY env
- SSHInteractiveSession: export the same in the initial shell command

`cat` streams the output through instead of blocking, and also covers other
pager-using tools (man, systemctl, journalctl). Adds regression tests.

Fixes #1697
2026-06-13 21:17:57 +08:00
Alessandro
2b99ab53c6 Gate remote tool prompts by connector metadata
Some checks are pending
Build And Publish Docker Images / plan (push) Waiting to run
Build And Publish Docker Images / build (push) Blocked by required conditions
Hide A0 connector remote tool prompts unless a connected CLI advertises the matching capability. Remote file access enables text_editor_remote, F4-enabled remote execution enables code_execution_remote, and supported enabled Computer Use that is not in rearm-required state enables computer_use_remote.

Apply the same gate to Responses API function-tool generation, move the prompt hook to the active tool-prompt extension path, and update connector prompt wording, DOX, and regression coverage.

Verified with:
- conda run -n a0 pytest tests/test_a0_connector_prompt_gating.py tests/test_default_prompt_budget.py tests/test_responses_architecture.py -q
2026-06-13 02:00:32 +02:00
Alessandro
8e270c5ab7 Ignore non-Telegram tool streaming contexts
Make Telegram tool lifecycle hooks no-op for contexts that do not expose a raw data dict or do not carry the Telegram bot marker.

This keeps global tool extension dispatch safe for non-Telegram contexts, including Responses API tool-call regression tests, without changing behavior for real Telegram sessions.
2026-06-11 19:14:03 +02:00
Alessandro
d6e8f06ec0 Clear stale preset kwargs on model switches
Treat model-slot kwargs as provider-specific preset fields: applying a preset now replaces explicit kwargs and clears inherited kwargs when the preset omits them, while preserving durable tuning like context windows and rate limits.

Mirror the behavior in the WebUI preset merge helper and add regressions for Codex-like presets so unsupported parameters such as temperature cannot leak into Responses API providers.
2026-06-11 19:13:47 +02:00