Root Cause: In backend/open_webui/functions.py, generate_function_chat_completion only calls get_tools() for user-defined tools, but never calls get_builtin_tools() for built-in tools (web_search, image_generation, execute_code, etc.).
Fix: Added call to get_builtin_tools() and merged results into extra_params['__tools__'] after the get_tools() call:
# Include built-in tools (web_search, image_generation, etc.)builtin_tools=get_builtin_tools(request,extra_params,metadata.get('features',{}),model_info,)forname,tool_dictinbuiltin_tools.items():ifnamenotinextra_params['__tools__']:extra_params['__tools__'][name]=tool_dict
This ensures that when a Pipe function receives __tools__, it includes all available tools — both user-defined and built-in — matching the behavior in middleware.py.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/open-webui/open-webui/pull/23465
**Author:** [@D2758695161](https://github.com/D2758695161)
**Created:** 4/7/2026
**Status:** ❌ Closed
**Base:** `main` ← **Head:** `fix/builtin-tools-in-pipes`
---
### 📝 Commits (1)
- [`686dc3e`](https://github.com/open-webui/open-webui/commit/686dc3e118092e215f8852beefe1d7913fa9b888) fix: include built-in tools in __tools__ for Pipe functions
### 📊 Changes
**1 file changed** (+12 additions, -1 deletions)
<details>
<summary>View changed files</summary>
📝 `backend/open_webui/functions.py` (+12 -1)
</details>
### 📄 Description
## Fix: Built-in tools missing from __tools__ in Pipe functions
**Issue:** #23365
**Root Cause:** In `backend/open_webui/functions.py`, `generate_function_chat_completion` only calls `get_tools()` for user-defined tools, but never calls `get_builtin_tools()` for built-in tools (web_search, image_generation, execute_code, etc.).
**Fix:** Added call to `get_builtin_tools()` and merged results into `extra_params['__tools__']` after the `get_tools()` call:
```python
# Include built-in tools (web_search, image_generation, etc.)
builtin_tools = get_builtin_tools(
request,
extra_params,
metadata.get('features', {}),
model_info,
)
for name, tool_dict in builtin_tools.items():
if name not in extra_params['__tools__']:
extra_params['__tools__'][name] = tool_dict
```
This ensures that when a Pipe function receives `__tools__`, it includes all available tools — both user-defined and built-in — matching the behavior in `middleware.py`.
Fixes #23365
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/23465
Author: @D2758695161
Created: 4/7/2026
Status: ❌ Closed
Base:
main← Head:fix/builtin-tools-in-pipes📝 Commits (1)
686dc3efix: include built-in tools in tools for Pipe functions📊 Changes
1 file changed (+12 additions, -1 deletions)
View changed files
📝
backend/open_webui/functions.py(+12 -1)📄 Description
Fix: Built-in tools missing from tools in Pipe functions
Issue: #23365
Root Cause: In
backend/open_webui/functions.py,generate_function_chat_completiononly callsget_tools()for user-defined tools, but never callsget_builtin_tools()for built-in tools (web_search, image_generation, execute_code, etc.).Fix: Added call to
get_builtin_tools()and merged results intoextra_params['__tools__']after theget_tools()call:This ensures that when a Pipe function receives
__tools__, it includes all available tools — both user-defined and built-in — matching the behavior inmiddleware.py.Fixes #23365
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.