Commit Graph
550 Commits
Author SHA1 Message Date
Xubin Ren 44a7ef53ce fix(webui): keep local appearance ready during settings loads 2026-10-25 22:14:58 +08:00
Xubin Ren ef8271b2c0 feat(webui): refine appearance and add custom reading sizes 2026-10-25 22:14:58 +08:00
chengyongru 8af6313c56 fix(webui): refresh pairing prompts on gateway changes (#6401) 2026-10-25 20:16:51 +08:00
david-dev666 9a9117967e feat(cron): expose recent run history to the agent 2026-10-25 14:21:47 +08:00
david-dev666 f971712f4f feat(cron): enable and disable jobs from the tool 2026-10-25 14:08:36 +08:00
david-dev666 60fd7c1a64 feat(cron): update scheduled tasks in place 2026-10-25 13:42:15 +08:00
Ruiming Zhao 6b930432cb fix: decode nested JSON tool arguments by schema 2026-10-25 13:04:53 +08:00
Zhou c9bd5ebb45 fix: recover oversized pending file reads after compaction 2026-10-25 12:37:34 +08:00
Xubin Ren 0bdc24a891 feat(webui): show image attachments as composer thumbnails 2026-10-25 00:09:24 +08:00
Xubin Ren 0b22c1875a fix(webui): separate file cards from media previews 2026-10-24 23:55:10 +08:00
er-s-an f4aacdbec2 fix(agent): don't resume abandoned work after max_iterations 2026-10-24 22:34:11 +08:00
chengyongruandXubin Ren ae7fed88e2 perf(tui): shrink standalone builds and target native bindings (#6432)
* perf(tui): shrink standalone builds without dropping features

* fix(tui): resolve macOS diagram fonts through CoreText

* fix(webui): preserve history pagination at the page boundary

* docs(tui): streamline release preflight guidance

---------

Co-authored-by: Xubin Ren <52506698+Re-bin@users.noreply.github.com>
2026-10-24 22:00:50 +08:00
ljluestc 0e0df327c8 fix(api): route each session_id to its own chat
Derive the request chat route from the existing API session key for both
JSON responses and SSE. Keep JSON identity conversion, multipart trimming,
the shared default session and persisted history unchanged.

Exercise concurrent HTTP/SSE requests through the real agent runtime, tools
and storage with an offline model. Verify old-history replay, restart,
rollback, session ordering and stable model-request prefixes.

Refs HKUDS/nanobot#5798
2026-10-24 21:59:12 +08:00
chengyongru 06f3981962 fix(mcp): remove Figma remote preset and open management (#6399)
* feat(mcp): configure OAuth client names in management

* fix(mcp): use a short OAuth callback for Figma

* fix(mcp): narrow catalog changes and remove Figma remote

* test(mcp): drop unpublished Figma remote compatibility contract

* fix(webui): align MCP catalog skeleton with card body
2026-10-23 01:15:14 +08:00
chengyongru 6ace6068d7 fix(webui): check for updates only after opening About (#6397)
* fix(webui): check for updates only after opening About

* docs(agent): require meaningful behavioral test assertions
2026-10-22 21:04:21 +08:00
chengyongru 254f94b068 feat(attachments): support local files and video attachments (#6321)
* feat(attachments): support local files and video attachments

Share gateway inspection and send validation for borrowed local paths while preserving binary uploads, original-file ownership, and existing limits.

Related to NAN-284. Native provider video input remains outside this change.

* test: make cross-platform verification fixtures self-contained

* test(webui): align typed fixtures with runtime contracts

* fix(webui): preserve uploaded video playback during history sync

* test(tui): preserve local attachment drafts across resizes

* perf(attachments): preserve upload caches and release video previews

* docs(webui): keep attachment guidance user-focused

* chore: remove redundant dependency comment

* test(providers): make stream idle renewal timing deterministic

* fix(attachments): keep upload byte limits out of local references

Validate common format/count rules separately from upload byte budgets. Keep local inspection and send-time checks metadata-only, and exclude local references from composer and pending-upload totals. Explain upload size rejections with actual size and maximum in all ten locales. Related to NAN-284.

* fix(attachments): retain image references and draft order

* fix(attachments): close local reference UX and authorization gaps

* fix(attachments): preserve focus during asynchronous path confirmation
2026-10-22 18:32:18 +08:00
chengyongru 7dfeff9ddf fix(webui): keep restored waiting messages manual (NAN-275) (#6393) 2026-10-22 17:43:28 +08:00
chengyongru 169062be11 fix(webui): offer restart in installed channel rows (NAN-334) (#6392)
* fix(webui): offer restart in installed channel rows (NAN-334)

* fix(webui): align channel restart icon and hover hint

* fix(webui): explain channel installs blocked by restart
2026-10-22 17:03:02 +08:00
chengyongru 08ca3b4525 refactor(webui): use native link actions and remove website previews (#6391)
* refactor(webui): remove website previews and custom link menus

* docs(webui): focus guide on product-specific usage
2026-10-22 16:34:54 +08:00
chengyongru 084b6bb394 feat(network): centralize proxy settings and add MCP routing (NAN-315) (#6372)
* feat(network): share proxy settings across features and MCP (NAN-315)

* fix(network): address shared proxy review regressions

* test(network): align rebased OAuth fixtures with runtime admission

* fix(webui): configure shared proxy without leaving connection drafts

* feat(webui): add optional shared proxy authentication editor

* fix(webui): align proxy save tests and loading skeleton
2026-10-22 15:49:27 +08:00
chengyongru f11ea5f9e0 feat(webui): configure idle compaction timeout (NAN-305) (#6383)
* feat(webui): configure idle compaction timeout (NAN-305)

* fix(webui): clarify idle compaction timeout and tradeoff

* refactor(webui): remove unused idle compaction minimum

* fix(webui): match idle compaction loading skeleton
2026-10-22 13:41:05 +08:00
chengyongru 26e1f41a00 fix(exec): yield long-running commands by default (NAN-328) (#6385)
* fix(exec): yield long-running commands by default (NAN-328)

* test(exec): avoid waiting for already observed output

* test(exec): observe hard-timeout cleanup before asserting completion
2026-10-22 13:27:26 +08:00
chengyongru 130f4edefe fix(qq): clarify QR binding states and setup actions (#6340)
* fix(qq): clarify QR binding states and setup actions

* fix(qq): confirm rebinding instead of showing a persistent warning

* fix(qq): make rebind credential warning conditional

* docs(qq): align rebind guide with conditional warning
2026-10-22 01:55:20 +08:00
chengyongru 67fc220c8a ci: scope native acceptance and bind release candidate artifacts (#6378)
* ci: scope native acceptance and bind release candidate artifacts

* ci: isolate Windows installers and use portable Git tree fixtures

* test: preserve installer subprocess diagnostics on timeout
2026-10-21 23:50:58 +08:00
Xubin Renandchengyongru fbb61a373f feat(update): integrate managed installs and recoverable in-app updates (#6168)
Add owner-aware Stable and Preview updates with explicit consent, verified release plans, protected process handoff and bounded service recovery. Keep configuration and conversations separate from program rollback.

Include the compact About controls, Windows long-path support, native package recovery checks and optional macOS Dock lifecycle integration. Preserve documented guidance for installations owned by other managers.

This code integration does not publish packages, enable signing or advance the public update channel.

Co-authored-by: chengyongru <61816729+chengyongru@users.noreply.github.com>
2026-10-21 19:16:56 +08:00
chengyongru b32b1327ce refactor(session): unify model and display history storage (#6336)
* refactor(session): persist display history in SQLite

* fix(session): preserve new fork activity timestamps

* test(agent): use SQLite-owned model failure recovery fixture

* test(agent): isolate session slash routing from loop shutdown

Exercise the real inbound dispatcher and await its session worker. Keep response deadlines and behavioral assertions, while leaving full SQLite cleanup to the existing async fixture rather than an unrelated two-second shutdown deadline.

* fix(webui): admit direct deliveries to display history

* docs: clarify session history migration guidance
2026-10-21 16:13:59 +08:00
chengyongru 743c51e81f fix(webui): stabilize earlier-history loading and reclaim space (#6349)
* fix(webui): retain smoothly revealed history loading headers

* refactor(webui): simplify history loading feedback

* fix(webui): keep retained history headers clear of preceding text

* fix(webui): reclaim completed history loading space

* refactor(webui): group history projection handoff with navigation

* test(webui): synchronize history motion observations

* fix(webui): collapse history completion geometry handoff
2026-10-21 13:10:05 +08:00
chengyongru 73a55e0b2f fix(gateway): request graceful Windows shutdown (#6353)
* fix(gateway): request graceful Windows shutdown

* docs(cli): simplify Windows gateway stop guidance

* test(gateway): compare native Windows owner SIDs
2026-10-21 11:05:30 +08:00
Xubin Ren 28f6c26946 fix(webui): recover model failures and align chat controls 2026-10-21 02:34:09 +08:00
bingqilinweimaotaiandClaude Code 6741acb391 feat(qq): add QR scan connection for QQ bots
Scan the official QQ Bot binding page from Channels → QQ or
`nanobot channels login qq`; the returned AppID and encrypted secret are
decrypted locally, saved to config, and the channel is enabled by the
existing post-connect flow. The WebUI keeps manual entry of AppID and
Secret in Advanced, restores every QQ setup field there, and warns that
scanning again rotates the App Secret and invalidates the previous one.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-20 21:55:17 +08:00
chengyongru 282839cc65 feat(webui): add reading text size preferences (#6325)
* feat(webui): add reading text size preferences

* fix(webui): align loading skeletons with reading typography
2026-10-20 16:33:05 +08:00
chengyongru 11152626f8 fix(webui): refine browser notifications (NAN-227)
Reconcile the original notification fix with the integrated main snapshot.

Group notification settings and simplify localized copy and documentation.
Preserve permission opt-out and notification click routing across app transitions.
Suppress late completion notifications for discarded temporary chats and align
notification settings skeletons with the loaded layout.
2026-10-20 13:45:04 +08:00
Xubin Ren 7b2af031c0 fix(webui): make browser notification failures actionable 2026-10-20 13:45:04 +08:00
chengyongru 909b277e7a fix(webui): recognize typed session handles as references (#6311)
* fix(webui): recognize typed session handles as references

Refs NAN-286

* refactor(webui): simplify session reference handling

* fix(webui): recognize mentions after punctuation

* docs(webui): focus topic references on usage
2026-10-20 01:05:11 +08:00
chengyongru 125d9221d0 fix(webui): merge consecutive waiting messages (#6309)
* fix(webui): merge consecutive waiting messages

* fix(webui): retain legacy draft session targets on refresh
2026-10-19 21:06:46 +08:00
chengyongru f57018aa7f feat(webui): render Mermaid diagrams with Pele (#6302)
* feat(webui): render Mermaid diagrams with Pele

* fix(webui): reserve diagram replacement capacity

* fix(webui): prebundle lazy diagram worker dependencies

* fix(webui): account diagram capacity by encoded size

* fix(webui): use shared hover hints for diagram actions

* docs(webui): focus diagram guide on usage
2026-10-19 17:16:20 +08:00
chengyongru dca49c258a fix(tools): refine DeepSeek search credentials and query validation
Require a configured Search API key while preserving explicit ${VAR_NAME} references.
Reject overlong Unicode queries locally instead of silently truncating them.
Keep the shared Settings flow and condense the configuration documentation.
2026-10-19 16:50:17 +08:00
moran e5b469ebd4 feat(tools): add DeepSeek Search as a web_search provider
Add a standalone `deepseek` search backend that calls the DeepSeek Search
API (POST https://api.deepseek.com/v1/tools/search), following the
provider layout used by AnySearch (#5607) and Bocha (#4182).

This is a search-only integration. It does not touch the DeepSeek LLM
provider, does not inject a `web_search` tool into model requests, and
does not implement the Fetch endpoint.

- Trim and truncate queries to the API's 128 Unicode-character limit
  locally, rejecting whitespace-only queries without a network call.
- Clamp `count` to the API's 1-50 range and always send
  `need_content: false` so page bodies stay out of the model context.
- Format results from `summary`, falling back to `snippet` when a summary
  is missing or blank, and include `date` when present. Cap each result's
  text at 500 characters: live responses reach ~4,500 characters, so ten
  uncapped results cost roughly 10k tokens per call.
- Return actionable 401 and 402 messages; retry 408/429/5xx once after
  1.0s like the Brave provider; surface `error.message` for other 4xx,
  tag-stripped because the upstream body is untrusted. Unexpected
  transport errors report the exception type only, with the detail
  logged when tool log content is allowed.
- Read the key from `tools.web.search.apiKey` or `DEEPSEEK_API_KEY` and
  fall back to DuckDuckGo when neither is set, like other keyed
  providers. The key is never logged or echoed in errors.
- Register the provider for the CLI wizard and WebUI settings, and reuse
  the bundled DeepSeek brand asset.
2026-10-19 16:50:17 +08:00
chengyongru 103840171b fix(docker): preserve explicit config selectors during bootstrap
Only initialize the Compose default instance when no --config/-c selector is present. Preserve all CLI-supported selector spellings and cover gateway/API startup against selected persisted settings in the Docker smoke test.
2026-10-19 13:02:26 +08:00
chengyongru de8fbc3ad2 fix(api): keep unconfigured services running and preserve Docker onboarding 2026-10-19 13:02:26 +08:00
chengyongru e20737a509 fix(docker): validate and atomically save first-boot configuration 2026-10-19 13:02:26 +08:00
LuckVd ddd22a26f8 Bootstrap a working Docker Compose config on first boot so the WebUI works out of the box
A fresh 'docker compose up' started with no config (the entrypoint only
bootstrapped for Render), so every published port was unreachable: the
gateway and WebSocket channel defaulted to a container-local 127.0.0.1
bind, and nanobot-api exited into a restart loop because serve refuses a
non-loopback host without an api_key.

Bootstrap config.json for container runs (NANOBOT_DOCKER_BOOTSTRAP, set
by docker-compose.yml) from a committed docker-config.json with binds
that survive the container boundary, baking the WebUI token and API key
at first boot (env value if provided, generated otherwise, printed to
the log). Move nanobot-api under the 'api' profile since it cannot
serve before a provider is configured. Install curl in the image and
document the new first-boot flow.

Fixes #6165
2026-10-19 13:02:26 +08:00
chengyongru 1832255995 docs: make user guidance easier to follow 2026-10-19 10:11:45 +08:00
chengyongru 0a8b18fa58 fix(deepseek): align model capabilities with the official API (#6283)
* fix(deepseek): preserve vision for legacy Flash aliases

* fix(deepseek): expose validated model catalog capabilities

* fix(deepseek): retain explicit off control with live reasoning levels

* docs: clarify provider-specific model guidance
2026-10-18 19:17:05 +08:00
Xubin Ren f9a3e55b64 perf(webui): revalidate prompt summaries and bound navigation work 2026-10-18 17:13:18 +08:00
Xubin Ren bf1eada575 fix(webui): navigate complete prompt history with bounded pages 2026-10-18 17:13:18 +08:00
Xubin Ren c49d84b4e5 fix(whatsapp_agent): retain unsent scheduled results across reconnects 2026-10-18 14:49:49 +08:00
Xubin Ren 86f16ff493 fix(whatsapp_agent): clarify privacy and align current channel setup 2026-10-18 14:49:49 +08:00
Xubin Ren 5a0f2c2dc3 fix(whatsapp_agent): preserve poll continuity and partial delivery progress 2026-10-18 14:49:49 +08:00
Carmelo Campos b7cb5da4b5 feat(channels): add WhatsApp Agent Platform channel
Adds `whatsapp_agent`, an additive channel that connects nanobot to the
official WhatsApp Agent Platform API (https://api.whatsapp.com/agent/v1).
It authenticates with a per-agent API token and long-polls `GET /updates`
instead of linking a device, so it is the officially supported interface
rather than the Neonize linked-device protocol used by the existing
`whatsapp` channel.

The existing `whatsapp` channel is unchanged; both can run at once under
different names.

Design notes:
- The poll cursor, dedup window, and creator identifier live in one
  atomically replaced state file. A message id is recorded before it is
  handled, so a crash re-reads the batch without answering twice, and the
  cursor is only accepted after the batch is processed.
- The first poll omits `offset`, which resolves the head and never replays
  up to 30 days of history into an auto-replying agent.
- A changed token resets the cursor, because `next_offset` is only valid
  for the agent that issued it.
- Each API method is paced below its own rolling 60-second limit, and
  progress/tool-hint messages default to off because they spend the shared
  12-per-minute send budget.
- Retries are limited to confirmed non-delivery (`429`, `503`/`131016`).
  A `500` or read timeout is ambiguous, so it is not retried unless
  `retryAmbiguousSends` is set; a duplicate is worse than a missed reply.
- Inbound media is downloaded through the shared SSRF guard, size-capped,
  and verified against the reported digest. Outbound media is validated
  before upload.
- Reactions are receive-only, matching the API. The token is never logged
  or persisted; state stores only a SHA-256 fingerprint.

Docs compare both WhatsApp channels, including the lack of end-to-end
encryption, country availability, and rate limits.
2026-10-18 14:49:49 +08:00