Learning from Bing Search
UFO can enhance the AppAgent by searching for information on Bing to obtain up-to-date knowledge for niche tasks or applications beyond the AppAgent's existing knowledge base.
Mechanism
When processing a request, the AppAgent:
- Constructs a Bing search query based on the request context
- Retrieves top-k search results from Bing
- Extracts relevant information from the search results
- Generates a plan informed by the retrieved information
This mechanism is particularly useful for: - Tasks requiring current information (e.g., latest software features, current events) - Applications or domains not covered by the agent's training data - Dynamic information that changes frequently
Configuration
To enable Bing search integration:
-
Obtain Bing API Key: Get your API key from Microsoft Azure Bing Search API
-
Configure Parameters: Set the following options in
config.yaml:
| Configuration Option | Description | Type | Default |
|---|---|---|---|
RAG_ONLINE_SEARCH |
Enable Bing search integration | Boolean | False |
BING_API_KEY |
Bing Search API key | String | "" |
RAG_ONLINE_SEARCH_TOPK |
Number of search results to retrieve | Integer | 5 |
RAG_ONLINE_RETRIEVED_TOPK |
Number of retrieved results to include in prompt | Integer | 5 |
For more details on RAG configuration, see the RAG Configuration Guide.
API Reference
Bases: Retriever
Class to create online retrievers.
Create a new OfflineDocRetriever. :query: The query to create an indexer for. :top_k: The number of documents to retrieve.
Source code in rag/retriever.py
168 169 170 171 172 173 174 175 | |
get_indexer(top_k)
Create an online search indexer.
| Parameters: |
|
|---|
| Returns: |
|
|---|
Source code in rag/retriever.py
177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 | |