web search stuff

This commit is contained in:
DrMelone
2026-01-05 20:55:24 +01:00
parent 5e9c9e47b7
commit 8130254c3c
3 changed files with 76 additions and 0 deletions

View File

@@ -60,3 +60,8 @@ Because the model can call `web_search` multiple times, it can perform "Deep Res
7. **Finalize**: Answer the user with grounded, verified information.
This iterative loop of **Thought → Action → Thought** continues until the model has sufficient information to answer your request with maximum accuracy.
## Next Steps
- **Save your findings**: Learn how to [save web search results directly to your Knowledge Base](./save-to-knowledge).
- **Troubleshoot**: If you encounter issues, check the [Web Search Troubleshooting Guide](../../troubleshooting/web-search).

View File

@@ -0,0 +1,64 @@
---
sidebar_position: 10
title: "Save Search Results to Knowledge"
---
# Save Search Results to Knowledge 📚
The **Add Web Sources to Knowledge Action** allows you to save web search result URLs directly to your Knowledge Base with a single click. This feature streamlines the process of building a research bank by automating the fetching, sanitizing, and uploading of web content.
## Features
- **One-Click Saving**: Quickly add selected sources from a chat message to any Knowledge Base.
- **URL Selection**: Choose specific URLs to save from a numbered list.
- **Batch Processing**: Handle multiple URLs in a single action.
- **Duplicate Detection**: Automatically skip URLs that already exist in the target Knowledge Base.
- **Configurable Defaults**: Set a default Knowledge Base and skip confirmation dialogs for a faster workflow.
## Setup
The "Add Web Sources to Knowledge" feature is implemented as a **Function Action**. To use it:
1. **Download the Action**: Visit the Open WebUI Community Hub and download the [Add Web Sources to Knowledge Action](https://openwebui.com/posts/65d97417-d079-4720-b2cc-a63dd59b7e3e).
2. **Enable the Action**:
* Navigate to **Workspace > Functions**.
* Import or create a new function with the provided code.
* Enable the action globally or for specific models.
## How to Use
1. **Trigger Web Search**: Ask a question that triggers web search (e.g., using DDGS, Google PSE, etc.).
2. **Click the Action Button**: Once the model returns citations, click the **folder+** icon in the message toolbar.
3. **Select Sources**: A dialog will appear. Enter the numbers of the sources you wish to save (e.g., `1,3,5` or `1-3` or `all`).
4. **Choose Knowledge Base**: Select the target Knowledge Base where the content should be saved.
5. **Done**: The system will fetch the content using your configured **Web Loader** and add it to the Knowledge Base.
## Configuration (Valves)
You can customize the action's behavior through **Valves** in the function settings.
### Admin Settings (Global Defaults)
| Setting | Default | Description |
|---------|---------|-------------|
| `max_urls_per_action` | `10` | Maximum number of URLs to process in a single action. |
| `enable_duplicate_check` | `True` | Check if URL already exists in the Knowledge Base before adding. |
| `default_knowledge_base` | `""` | System-wide default Knowledge Base name or ID. |
| `skip_confirmation` | `False` | Skip confirmation dialogs and use the default Knowledge Base. |
| `file_name_prefix` | `""` | Prefix for generated file names (e.g., `web_`). |
### User Settings (Personal Overrides)
Users can override global defaults in their own settings:
- **Default Knowledge Base**: Set a preferred KB to avoid manual selection.
- **Skip Confirmation**: Enable for instant one-click saving (requires a default KB).
- **File Name Prefix**: Customize the prefix for your saved sources.
:::tip Power User Tip
Set your **Default Knowledge Base** and enable **Skip Confirmation** in your User Valves to achieve instant, one-click saving of web sources!
:::
## Troubleshooting
- **Content Quality**: The quality of the saved content depends on your **Web Loader Engine** settings (Admin > Settings > Documents). For JavaScript-heavy sites, consider using **Firecrawl** or **Playwright**.
- **No URLs Found**: This action works with web search results that return structured citations. If no URLs are detected, ensure web search is properly enabled and returning results.

View File

@@ -3131,6 +3131,13 @@ Allow only specific domains: WEB_FETCH_FILTER_LIST="example.com,trusted-site.org
- Description: Bypasses the web search embedding and retrieval process.
- Persistence: This environment variable is a `PersistentConfig` variable.
#### `BYPASS_WEB_SEARCH_WEB_LOADER`
- Type: `bool`
- Default: `False`
- Description: Bypasses the web loader when performing web search. When enabled, only snippets from the search engine are used, and the full page content is not fetched.
- Persistence: This environment variable is a `PersistentConfig` variable.
#### `SEARXNG_QUERY_URL`
- Type: `str`