mirror of
https://github.com/open-webui/open-webui.git
synced 2026-06-07 09:19:06 -05:00
How to Expose an External API for the RAG Environment in open-webui with Ollama? #4117
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 @Lance-He on GitHub (Feb 25, 2025).
I have successfully deployed open-webui locally, configured it to call deepseek R1 via the Ollama API, and uploaded my own knowledge base. However, I am currently facing a challenge: I need to expose my configured RAG environment as an external API so that it can be accessed by external applications (e.g., my chatbot).
Specifically, I’m looking for guidance on the following points:
API Endpoint Creation:
What is the recommended approach to create an external API endpoint that wraps the RAG functionality?
Should I integrate a lightweight web framework like Flask or FastAPI into my current setup, or is there a built-in method within open-webui?
Integration with Existing Configuration:
How can I ensure that the API correctly leverages the existing open-webui configuration and the ollama interface (calling deepseek R1) for model inference and knowledge retrieval?
Any detailed examples, configuration snippets, or pointers to documentation would be greatly appreciated. Thank you for your assistance!