[GH-ISSUE #3609] /ollama/api/generate api for customGPTs #13323

Closed
opened 2026-04-19 20:05:46 -05:00 by GiteaMirror · 0 comments
Owner

Originally created by @veya2ztn on GitHub (Jul 3, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/3609

The openwebup support api usage like [OWEB]/ollama/api/generate for base mode loaded from ollama.
However, if I want to wrapper the base model (for example, the qwen2 model) with certern

  • system prompt
  • knowledge base for RAG
    The [OWEB]/ollama/api/generate will return status code: 400.

below is a sample that get property result via [OWEB]/ollama/api/generate , the model named qwen2:72b-instruct-q4_0
image

If I wrapper it in a customGPTs that even with no any extra setting. (we name it qwentest)
image

The reason for such suggestion.

The [OWEB]/ollama/api/generate is usually for the code completion task. Currently, it barely base on the ability of the base model such as starcode2 or deepseek-code. Enable preset prompt may help to build much more robust code. Moreover, I also wise the code completion can eventully become text completion that for writting as copilot way

Originally created by @veya2ztn on GitHub (Jul 3, 2024). Original GitHub issue: https://github.com/open-webui/open-webui/issues/3609 The openwebup support api usage like `[OWEB]/ollama/api/generate` for base mode loaded from ollama. However, if I want to wrapper the base model (for example, the `qwen2` model) with certern - system prompt - knowledge base for RAG The `[OWEB]/ollama/api/generate` will return ` status code: 400`. below is a sample that get property result via `[OWEB]/ollama/api/generate` , the model named `qwen2:72b-instruct-q4_0` ![image](https://github.com/open-webui/open-webui/assets/18117225/b53e2760-797c-42ab-9539-788f65b5c4de) If I wrapper it in a customGPTs that even with no any extra setting. (we name it `qwentest`) ![image](https://github.com/open-webui/open-webui/assets/18117225/c0ff7353-9201-41d6-ac82-2ba5171ac4ee) ---------- # The reason for such suggestion. The `[OWEB]/ollama/api/generate` is usually for the `code completion` task. Currently, it barely base on the ability of the base model such as starcode2 or deepseek-code. Enable preset prompt may help to build much more robust code. Moreover, I also wise the `code completion` can eventully become `text completion` that for `writting as copilot way`
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#13323