Skip to content

Pin Open WebUI v0.12.4.10 (GenAI spans on every path) and survive its cold start - #81

Merged
SushantGautam merged 3 commits into
mainfrom
chore/openwebui-0.12.4.10
Nov 5, 2026
Merged

SushantGautam merged 3 commits into
mainfrom
chore/openwebui-0.12.4.10

Conversation

@SushantGautam

Copy link
Copy Markdown
Collaborator

Open WebUI v0.12.4.10-subpath

Fork PR SushantGautam/open-webui#11 audited every place Open WebUI reads content, runs tools or calls models, and closed the gaps in GenAI tracing:

  • Retrieval spans with gen_ai.retrieval.documents for every content-reading built-in tool (knowledge files and grep, kb_exec, chat files, notes, chats, channel messages and threads, memories, web search and fetch), and for memory recall. Each span names its data source.
  • execute_tool spans in default (non-native) function calling.
  • chat spans for pipe (function) models.
  • An embeddings span for query_knowledge_files' query.

This fixes D10-style checks that saw "0 retrieved documents" when an agent read a file with view_knowledge_file instead of searching. Studio needs no code change for the new spans: it already reads retrieval spans.

Cold-start fix

Right after Open WebUI starts, its model registry can miss the agent: Studio's throttled refresh may run before Open WebUI loads its connections. In testing, 6 of 10 concurrent scenarios failed with "Model not found". A saved-chat request that gets that answer now reloads the registry immediately and retries once.

Checks

  • uv run pytest -m "not embedded_hatchet": 1628 passed before the retry commit; the engine tests (71) pass with it.
  • uv run ruff check .: clean.
  • Live, on the published 0.12.4.10 wheel, starting a 5-turn audit right after a cold start: 10 of 10 scenarios pass with every check passing, no "Model not found", and 27 knowledge retrieval spans (26 with documents).
  • Live, with ENABLE_KB_EXEC=false: view_knowledge_file and grep_knowledge_files each produced a retrieval span with customer_faq.md as the document.

GenAI spans on every content, tool and model path (fork #11): retrieval spans
with documents for every content-reading built-in tool (knowledge files and
grep, chat files, notes, chats, channels, memories, web search and fetch) and
for memory recall, execute_tool spans in default function calling, and chat
spans for pipe models. Fixes checks that counted no retrieved documents when an
agent read a file with view_knowledge_file instead of searching.
Right after Open WebUI starts, its model registry can still miss the agent when
Studio's once-a-minute refresh ran before Open WebUI loaded its connections, so
concurrent scenarios failed with 'Model not found'. A saved-chat request that
gets that answer now reloads the registry immediately and retries once.
Copilot AI balanced review requested due to automatic review settings November 4, 2026 23:52

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

test_concurrent_runs_keep_their_own_auditor_class called mock.patch from two
threads at once on the same attributes (decision_target_for,
decision_auditor_class, snapshot_api_key). mock.patch is not thread-safe: one
thread could restore the other's mock, leaving it installed for every later test
on that xdist worker. That is the CI flake seen on #79 and #81 (snapshot_api_key
returning '', decision_target_for returning object(), the auditor class being
AuditorA). The test now patches once in the main thread, with side effects that
pick each thread's class from its own target.
@SushantGautam
SushantGautam merged commit 18dc829 into main Nov 5, 2026
2 checks passed
@SushantGautam
SushantGautam deleted the chore/openwebui-0.12.4.10 branch November 5, 2026 00:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants