David Siewert
612097b411
fix(config): align gci formatting for LLM retry fields
2026-04-25 23:01:45 +06:00
David Siewert
1b2f8aac79
fix(config): align indentation for new LLM retry default fields
2026-04-25 22:12:41 +06:00
David Siewert
32c8b8ce6a
chore(config): add default values for max_llm_retries and llm_retry_backoff_secs
2026-04-25 22:09:44 +06:00
David Siewert
d2f6a08981
fix(config): align gci formatting for MaxLLMRetries field
2026-04-25 22:07:16 +06:00
David Siewert
3c4523e7aa
test(agent): add unit tests for network error retry backoff strategy
...
- Test all network error types trigger retry (connection_reset, broken_pipe, read_tcp, eof, connection_refused)
- Test custom MaxLLMRetries and LLMRetryBackoffSecs config is respected
- Test retry count limit (1 initial + maxRetries retries)
- Add countingErrorProvider mock for deterministic call count verification
2026-04-25 21:19:13 +06:00
David Siewert
06fad95719
feat(agent): add network error retry with configurable max retries and backoff
...
- Add isNetworkError detection for connection reset, broken pipe, read/write tcp, EOF
- Add retry logic with configurable exponential backoff for network errors
- Add config options max_llm_retries and llm_retry_backoff_secs in agents.defaults
- Network errors now retry with backoff (was previously not retried)
- Timeout errors now use configurable backoff instead of hardcoded 5s
- Default: 2 retries with 2s backoff (3 total attempts)
2026-04-25 19:08:46 +06:00
Guoguo
6ca7311273
feat(agent): add context usage ring indicator and /context command ( #2537 )
...
Add a context window usage indicator to the web chat UI and a /context
slash command that works across all channels.
Backend:
- Add computeContextUsage() estimating history + system + tool tokens
- Attach ContextUsage to outbound messages via the pico WebSocket protocol
- Add /context command showing context stats as formatted text
- Add EstimateSystemTokens() on ContextBuilder for system prompt estimation
Frontend:
- Add ContextUsageRing component (SVG ring + hover/tap popover)
- Show usage percentage, token counts, and compression threshold
- Hover on desktop (150ms leave delay), tap on mobile
- "View Details" sends /context with 1s cooldown
- i18n support (en/zh) for popover labels
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-04-21 16:30:02 +08:00
LC
9c3dc0ee3a
fix(auth): canonicalize Google Antigravity provider and enhance credential management ( #2599 )
...
* fix(auth): canonicalize Google Antigravity provider and enhance credential management
* fix(auth): improve error handling in credential storage tests
* fix(auth): stabilize canonical provider merge precedence
2026-04-21 16:28:29 +08:00
wenjie
ba6992234f
feat(web): support list editing for channel array fields ( #2595 )
...
Add reusable channel array list controls and parsing utilities for channel forms.
Normalize channel string-array payloads in the backend, including pasted values,
numeric IDs, hidden characters, duplicates, and empty clears.
Also allow FlexibleStringSlice to unmarshal null values and cover the new behavior
with backend and config tests.
2026-04-21 16:04:28 +08:00
sky5454
329e68e017
refactor(agent): Agent Looper refactor phase2, restructure pipeline and rename loop files to agent ( #2585 )
...
* refactor(agent): introduce interfaces for MessageBus and ChannelManager
Phase 2 of loop.go refactor — dependency inversion using adapter pattern.
- Add interfaces.MessageBus and interfaces.ChannelManager interfaces
- Create adapters/messagebus.go wrapping *bus.MessageBus
- Create adapters/channelmanager.go wrapping *channels.Manager
- Update AgentLoop to use interfaces instead of concrete types
- Update registerSharedTools to accept interfaces.MessageBus
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
* refactor(agent): restructure pipeline and rename loop files
Pipeline refactoring:
- Split pipeline.go (1400 lines) into focused files:
- pipeline_setup.go (~115 lines): SetupTurn method
- pipeline_llm.go (~519 lines): CallLLM method
- pipeline_execute.go (~693 lines): ExecuteTools method
- pipeline_finalize.go (~78 lines): Finalize method
- Pipeline struct and NewPipeline remain in pipeline.go (~39 lines)
Agent file renaming:
- Rename loop_*.go to agent_*.go for consistent naming:
- loop.go -> agent.go, loop_message.go -> agent_message.go, etc.
- Merge turn.go + turn_exec.go into turn_state.go
- Rename loop_turn.go -> turn_coord.go
Documentation:
- Update docs/pipeline-restructuring-plan.md
- Add docs/agent-rename-plan.md
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com >
* fix(agent): code format fixed
* refactor(agent): code test file added/renamed
* docs(agent): update agent refactor docs
* fix(agent): fix agent hardAbortX
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-04-21 10:55:50 +08:00
lxowalle
6421f146a9
Revert "Feat/channel tool feedback animation ( #2569 )" ( #2596 )
...
This reverts commit e556a816e4 .
2026-04-20 18:30:29 +08:00
lxowalle
e556a816e4
Feat/channel tool feedback animation ( #2569 )
...
* feat(channels): unify tool feedback animation across discord telegram and feishu
* fix(tool-feedback): unify fallback and single-message delivery
* fix(channels): finalize tool feedback in place
* fix ci
* feat: improve tool feedback
2026-04-20 15:20:26 +08:00
wenjie
4b76196e2c
refactor(web): secure Pico websocket access behind launcher auth
...
- stop exposing the raw Pico token to the frontend
- add /api/pico/info for non-secret Pico connection metadata
- proxy /pico/ws through the launcher with same-origin and dashboard auth checks
- inject the upstream Pico websocket protocol server-side
- update frontend chat connection flow and Vite websocket proxy path
- refresh related docs and tests
2026-04-20 10:11:03 +08:00
美電球
6126ede963
Merge pull request #2566 from lc6464/refactor/providers-tools-layout
...
refactor(providers,tools): reorganize packages and facades
2026-04-17 22:51:49 +08:00
lc6464
743cd3602b
fix(tools): centralize shared LLM note constants
2026-04-17 14:31:43 +08:00
lc6464
9b4efddd9b
fix(providers,tools): address linter issues after reorg
2026-04-17 14:16:18 +08:00
wenjie
4e1ceee62e
refactor(docs): reorganize docs by type and locale
2026-04-17 14:00:45 +08:00
lc6464
4c133dc2d9
refactor(tools): reorganize tool packages and facades
2026-04-17 13:44:31 +08:00
daming大铭
0da962c4b4
Merge pull request #2564 from sky5454/looper_refactor
...
Looper refactor: Split the monolithic 4384-line `loop.go` into 12 focused source files as Phase 1 of the agent refactor.
2026-04-17 13:18:11 +08:00
lc6464
ee634dc8db
refactor(providers): reorganize provider packages and facades
2026-04-17 12:42:03 +08:00
sky5454
12d5421c26
refactor(agent): split loop.go into focused sub-packages
...
Break up the monolithic 4384-line loop.go into 12 focused files:
- loop.go: core AgentLoop struct and main Run loop
- loop_turn.go: turn execution logic (runTurn, askSideQuestion, etc.)
- loop_utils.go: pure utility functions (formatters, helpers)
- loop_init.go: constructor and tool registration
- loop_message.go: message handling (processMessage, routing)
- loop_command.go: command processing (/use, /btw, etc.)
- loop_mcp.go: MCP runtime management
- loop_event.go: event/hook system helpers
- loop_media.go: media resolution and artifact handling
- loop_outbound.go: response publishing
- loop_transcribe.go: audio transcription
- loop_steering.go: steering queue and continuation
- loop_inject.go: setter injection methods
No functional changes - pure code movement with updated imports.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-04-17 11:17:12 +08:00
daming大铭
928a27359f
Merge pull request #2549 from lc6464/gateway-auth-no-browser
...
feat(auth): add no-browser option for OAuth login
2026-04-17 09:54:03 +08:00
daming大铭
ba08d52351
Merge pull request #2474 from srcrs/fix-cron-independent-sessions
...
fix(cron): make each job execution use an independent session
2026-04-16 23:52:29 +08:00
daming大铭
b1475122da
Merge pull request #2547 from lc6464/chore/issue-2538-network-fallback
...
feat(network): improve network error classification and fallback handling
2026-04-16 23:17:20 +08:00
lc6464
ffd30d7db7
fix(auth): improve no-browser OAuth login
2026-04-16 23:01:28 +08:00
daming大铭
eb24269651
Merge pull request #2503 from cytown/loop
...
refactor: make agent loop support parallel and update docs
2026-04-16 22:47:34 +08:00
lc6464
2b844778ff
refactor(tests): extract common logic for fallback error handling into a helper function
2026-04-16 22:45:31 +08:00
lc6464
ab019d3f18
feat(auth): add no-browser option for OAuth login
2026-04-16 22:19:34 +08:00
LC
7aa2d672ce
fix(network): classify timeout errors as FailoverTimeout
...
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com >
2026-04-16 22:00:13 +08:00
lc6464
c3f4000817
feat(network): implement network error classification and fallback handling
2026-04-16 19:59:37 +08:00
wenjie
7fdc9c7b64
fix(web): support proxies in SearXNG and web fetch ( #2542 )
...
Propagate the configured HTTP client and proxy settings to the
SearXNG search provider.
Allow web_fetch to connect to the configured proxy as the first hop
without bypassing the existing private-host checks for redirect
targets and fetched URLs.
Add tests for loopback proxy fetches and SearXNG proxy propagation.
2026-04-16 17:15:47 +08:00
Cytown
f5e779e22e
refactor: make agent loop support parallel and update docs
2026-04-16 14:43:15 +08:00
lxowalle
e22b4e1eee
feat(agent): support btw side questions ( #2532 )
2026-04-16 10:53:09 +08:00
wenjie
a8d0b03515
fix(web): save channel configs with nested channel_list patches ( #2530 )
...
Persist channel settings through the current channel_list schema, keeping common
channel fields at the top level and channel-specific fields under settings.
Return common fields and default config shapes from channel config endpoints, and
add coverage for nested patches, missing channel defaults, and secret handling.
2026-04-16 10:30:16 +08:00
美電球
ead2dc9699
Merge pull request #2524 from SiYue-ZO/feature/sogou-web-search-default
...
Add configurable Sogou-backed web search
2026-04-15 20:50:53 +08:00
wenjie
7bd11181a6
fix(agent): preserve reused tool call IDs across turns ( #2528 )
...
Scope tool result deduplication to each assistant tool-call block so providers
that reuse call IDs across separate turns do not lose valid tool results. Also
drop invalid empty tool call IDs and orphaned tool messages after validation.
2026-04-15 20:18:09 +08:00
SiYue-ZO
2784223ad5
Make web search auto-switch with UI language
...
Default the sample web search provider to auto, route Sogou vs DuckDuckGo dynamically based on query/UI language, and sync frontend language changes back to the backend so Current Service and runtime selection stay aligned.
2026-04-15 18:45:28 +08:00
Mauro
bb14a5c7cc
Merge pull request #2525 from afjcjsbx/fix/vision-unsupported-media-stuck
...
fix(agent): recover after image-input-unsupported failures
2026-04-15 07:54:33 +02:00
SiYue-ZO
75e93b5189
Merge remote-tracking branch 'upstream/main' into feature/sogou-web-search-default
...
# Conflicts:
# pkg/tools/web.go
# pkg/tools/web_test.go
2026-04-15 13:28:05 +08:00
SiYue-ZO
0b84f0ae0a
fix(web): address sogou search review feedback
2026-04-15 13:03:06 +08:00
lxowalle
773a94c414
fix(web_search): validate missing API key/URL directly in Search methods ( #2517 )
2026-04-15 09:55:05 +08:00
afjcjsbx
e60a687387
fix lint
2026-04-14 22:35:02 +02:00
afjcjsbx
7824bc715f
add test
2026-04-14 22:31:30 +02:00
afjcjsbx
d3d639cb7d
fix lint
2026-04-14 22:21:33 +02:00
afjcjsbx
1245f2ddf6
fix(agent): recover after image-input-unsupported failures
2026-04-14 22:15:28 +02:00
srcrs
d8e7a6129f
fix(cron): add blank line between default and localmodule imports for gci
...
gci linter requires a blank line separating import sections (default vs
localmodule). Missing separator caused CI failure.
2026-04-15 02:07:35 +08:00
美電球
b52eb58f03
Merge pull request #2514 from lc6464/fix/issue-2488-host-binding
...
feat(launcher): add host overrides for launcher and gateway
2026-04-14 23:48:24 +08:00
lc6464
0bb9bedc44
fix(web): address latest Copilot review points
2026-04-14 23:39:59 +08:00
SiYue-ZO
dcf21ef11c
Fix provider return formatting for golines
2026-04-14 23:26:40 +08:00
SiYue-ZO
824e800d70
Fix Sogou user agent formatting for linter
2026-04-14 23:22:37 +08:00