mirror of
https://github.com/open-webui/docs.git
synced 2026-11-05 01:38:13 +00:00
[PR #1402] [MERGED] docs: correct the tool development and valves pages against tools.py, plugin.py and the valves renderer #1367
Labels
No labels
bug
documentation
documentation
duplicate
enhancement
enhancement
good first issue
good first issue
good first issue
help wanted
help wanted
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
open-webui/docs#1367
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/open-webui/docs/pull/1402
Author: @silentoplayz
Created: 9/18/2026
Status: ✅ Merged
Merged: 9/18/2026
Merged by: @Classic298
Base:
main← Head:docs/tools-development📝 Commits (1)
0aa4c33docs: correct the tool development and valves pages against tools.py, plugin.py and the valves renderer📊 Changes
2 files changed (+21 additions, -5 deletions)
View changed files
📝
docs/features/extensibility/plugin/development/valves.mdx(+3 -1)📝
docs/features/extensibility/plugin/tools/development.mdx(+18 -4)📄 Description
Summary
I compared the tool development and Valves pages with
utils/tools.py,utils/plugin.py,utils/middleware.pyand the Valves renderer ondev.__model__for a workspace tool is the task model when one is configured, not the chat model. The entry says so and points at__metadata__["model"].__init__must setself.valvesor stored admin valves are never applied.__parameters are stripped from it, and what each return type (string, dict, list, image data URI) turns into for the model.__id__,__chat_id__,__message_id__and__request__to the reserved arguments, thefile_handlerflag and the fact that only the Legacy path reads it, and the import-prefix rewrite that breaksfrom configparser import ....passwordandselectonly apply tostrfields, and a dynamic-options method must be synchronous and return a list.Related issue or discussion
None.
Checklist
Notes for reviewers
Sources on
dev:plugin.py(asyncio.to_threadaround the pip subprocess, the four import replacements,resolve_valves_schema_options),tools.py(get_functions_from_tool, valves loading, spec stripping of__names,get_task_model_idfeeding__model__),middleware.py(tool result handling andfile_handler), and the branch order insrc/lib/components/common/Valves.svelte.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.