mirror of
https://github.com/open-webui/pipelines.git
synced 2026-07-21 10:05:26 -04:00
Pipe Function Executes Before Inlet in Latest OWUI Version #191
Reference in New Issue
Block a user
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?
Originally created by @NTTLuke on GitHub (Feb 6, 2025).
Hi all,
with the latest version of OWUI, it seems that the pipe function is called before the inlet, and I can no longer handle this situation.
any suggestions ?
@pfedasullivan commented on GitHub (Feb 14, 2025):
I'm seeing the same issue and it is causing all sorts of problems.
@NTTLuke commented on GitHub (Feb 14, 2025):
Yes!
Especially if you have based your agents on that for retrieving information about the chat_id, as we do.
I have also opened an issue here:
https://github.com/open-webui/open-webui/issues/9515, but it has been closed.
I need to find time to document the scenario because the response doesn’t seem related to the behavior observed.
I understand that the pipe function is not asynchronous, but the issue originates from the invocation of the FastAPI endpoint of the pipeline service, which is asynchronous.
If you run version 0.5.7, the flow works correctly: the inlet endpoint (FastAPI route) is invoked, followed by the completion endpoint (FastAPI route).
However, starting from version 0.5.8, the inlet endpoint is not invoked properly.
@NTTLuke commented on GitHub (Feb 14, 2025):
I try to mention @tjbck to have more info about that maybe he can give us feedback how to manage the scenario.
We cannot migrate beyond version 0.5.7 due to this issue, which I believe is caused by some inversion of the invocation on the OpenWebUI side but correct me if I'm wrong.
Thanks a lot!
@pfedasullivan commented on GitHub (Feb 14, 2025):
I'm seeing the same thing. For me, I don't see inlet running at all, but that has the same effect as inlet running after pipe. It really shouldn't do that according to the documentation, and didn't do that throughout all the previous versions. We are stuck on prior versions as well.
@tjbck commented on GitHub (Feb 14, 2025):
Could we get backend logs for this issue? Issue templates exist for a reason 😅
@tjbck commented on GitHub (Feb 16, 2025):
@NTTLuke Latest Open WebUI dev might've addressed the issue. Testing wanted here!
@NTTLuke commented on GitHub (Feb 16, 2025):
Love you, man!
I see now since I’m in a different tz than yours
I’ll do it when I’m back home … even before I take shower 😜
I’ll keep u posted !
@NTTLuke commented on GitHub (Feb 16, 2025):
Hi @tjbck,
I have tested the dev.
Here are my thoughts:
Test 1: Using my actual pipeline (aka PipelineA) doesn't work.
Test 2: I created a new pipeline from scratch (PipelineB) with just a print, and it works fine.
Test 3: I copied the exact same code (identical) from my PipelineA into PipelineB, and it works.
However, PipelineA continues to not work.
Strange behavior but in conclusion, if I need to copy the old code into new pipelines, it's ok.
Let's just say that starting from scratch with a new pipeline the dev branch resolves the issue.
Thanks a lot !!!
@pfedasullivan any feedback on your side ?
@pfedasullivan commented on GitHub (Feb 17, 2025):
I've confirmed that I had to delete the original pipeline, and create a new pipeline with the same code for it to start working.
@arneschreuder commented on GitHub (Feb 17, 2025):
Unfortunately recreating the pipeline did not work for us. (Using v0.5.12).
More detail:
@NTTLuke commented on GitHub (Feb 17, 2025):
Let’s try changing the pipeline name , the id and the file name (your_pipeline.py ) in order to have different values compared to the actual one you are using .
With this trick my old pipelines work fine with the 0.5.12 and the dev branch .
@arneschreuder commented on GitHub (Feb 17, 2025):
I will give that a go! @NTTLuke thanks! Will revert back
@arneschreuder commented on GitHub (Feb 17, 2025):
@NTTLuke unfortunately, still doesn't work. I tried readding the pipeline using different names and config, still same problem. Inlet is not being called. I tried using the original langfuse pipeline as mentioned above and the updated/fixed langfuse pipeline in the PR mentioned above. Neither worked. Interestingly, I do get the autocompletion task traces in langfuse, which does hit the inlet. I will investigate more and get back on this as the actual chat does not get logged, as a result of the inlet not firing.
@NTTLuke commented on GitHub (Feb 17, 2025):
OMG ! Very strange
Last try : use the “dev” branch
@alejandrods commented on GitHub (Feb 18, 2025):
Same thing happens to me. I tried to create a new filter from scratch but I couldn't make it work.
@bhdresh commented on GitHub (Feb 18, 2025):
Initial testing shows that issue is not fixed in dev branch.
Test cases tried so far on dev branch,
NOTE: I have kept docker persistant volume using "-v open-webui:/app/backend/data" for all of the above test cases.
@ivanfioravanti commented on GitHub (Feb 24, 2025):
I confirm same issue, everything was working properly till 0.5.7. @tjbck any news?
@thiswillbeyourgithub commented on GitHub (Feb 24, 2025):
Hi, i opened that issue yesterday: https://github.com/open-webui/open-webui/issues/10632
It's an issue related to filter functions (not pipelines) where I noticed that modifying the body in inlet and outputting it resulted in no changes (the body seemed reset somehow to its original state).
I reproduced it, found other non working turn limiting filters and still had the issue. It somehow was not here anymore after restarting the docker compose.
So, i don't know if this is related to the issue here but encourage everyone to restart the app every time before actually testing anything because I suspect there are stateful issues in open-webui.
And btw: i made a debug filter that simply prints what goes through it, it's pretty useful! With priorities you can even sandwich another filter with it. Here's the link: https://github.com/thiswillbeyourgithub/openwebui_custom_pipes_filters/blob/main/filters/debug_filter.py
Hope it helps.
@savvaki commented on GitHub (Mar 20, 2025):
On the latest OWUI v0.5.20 this is how to reproduce (the inlet and outlet is not working at all for me):
Note this is a Function, which is added in the OWUI interface:
If I type a message to the function, this is the output of the container logs:
The environment used for OWUI: