agentscope-ai / agentscope-ai/QwenPaw

Add a per-chat toggle to enable/disable internet search capabilities, giving users control over when the agent can access external web data.

Aberta
#6,228 1 comentário 0 reações 0 responsáveis Ver no GitHub
enhancement
Linguagem predominante
Python
Estrelas
34.9k
Forks
3.1k
Merge médio
1d 15h
PRs com merge (30d)
225

Descrição

## Summary

Add a per-chat toggle to enable/disable internet search capabilities, giving users control over when the agent can access external web data.

## Component(s) Affected

- [x] Core / Backend (app, agents, config, providers, utils, local_models)
- [x] Console (frontend web UI)
- [ ] Channels (DingTalk, Feishu, QQ, Discord, iMessage, etc.)
- [ ] Skills
- [x] CLI
- [ ] Documentation (website)
- [ ] Tests
- [ ] CI/CD
- [ ] Scripts / Deploy

## Problem / Motivation

Users need control over when the agent searches the internet vs. works with local knowledge only. Current issues:

- **Privacy concerns**: Some conversations involve sensitive data that shouldn't trigger external requests
- **Offline work**: Users may want to work without internet dependency
- **Token/cost control**: Web searches consume additional tokens and time
- **Trust**: Users may prefer verified local knowledge over web results for certain tasks

Currently, users can verbally instruct the agent ("don't search the web"), but this:
- Relies on agent compliance
- Isn't enforced at the system level
- Can be forgotten across long conversations

## Proposed Solution

1. **UI Toggle**: Add a clear enable/disable switch for internet search in the Console chat interface
2. **Per-session setting**: Remember the search preference for each chat session
3. **Visual indicator**: Show whether search is enabled (icon, badge, or status bar)
4. **CLI support**: Add flag or command to toggle search in terminal UI
5. **System-level enforcement**: When disabled, block search tool calls at the backend level

Implementation options:
- Chat settings panel with "Internet Search" toggle
- Quick-access button in the chat header
- Slash command (e.g., `/search on` or `/search off`)
- Environment variable for default behavior

## Alternatives Considered

- **Verbal instructions**: "Don't search the web" — relies on agent compliance
- **Global config**: Disable search entirely in settings, but this affects all chats
- **Tool removal**: Uninstall search skills, but requires reinstallation to re-enable

## Additional Context

- Search tools affected: `searxng_web_search`, `fetch`, `browser_use` (when used for search)
- Similar to how browsers have offline mode or how some AI platforms have "online" toggles
- Aligns with QwenPaw's privacy-first design ("Yours, not ours" principle)

## Willing to Contribute

- [ ] I am willing to open a PR for this feature (after discussion).

Guia de contribuição

Abrir o guia de contribuição

Avaliação

Esta issue ainda não foi avaliada.

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.