mirror of
https://github.com/langgenius/dify-plugin-sdks.git
synced 2026-07-22 02:15:22 -04:00
[Feature]: OAICompatLargeLanguageModel: support video modal type
#66
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 @AkiraVoid on GitHub (Dec 1, 2025).
This issue is originally posted at https://github.com/langgenius/dify-official-plugins/issues/2127
Self Checks
1. Is this request related to a challenge you're experiencing? Tell me about your story.
I am using OpenAI API Compatible 0.0.25 and tried to upload file through Vision field and User Prompt, non of them being properly analyzed.
2. Additional context or comments
The current function of converting abstract PromptMessage into OpenAI API payload is defined as below:
https://github.com/langgenius/dify-plugin-sdks/blob/f1d201d9a88054cd70f08aaa12f8c13f8a6af6ed/python/dify_plugin/interfaces/model/openai_compatible/llm.py#L713-L781
which did not handle the video/audio/document modal properly (it just ignores them all).
3. Can you help us with this feature?
@sweetwxh commented on GitHub (Dec 4, 2025):
Can you pass the video-type prompt to _invoke with the built-in URL if the video feature is enabled? Make sure this URL is publicly accessible; right now it’s a base64-encoded string. If the URL is passed directly, the operation should be much easier. Besides, I’d like to write my own video-processing logic inside the openai_api_compatible plugin, but at the moment I have to upload the file to a CDN first, which is a waste of time.
@AkiraVoid commented on GitHub (Dec 4, 2025):
@sweetwxh Bro I am developing a custom plugin to solve this issue, and I can say that if your model provider supports video transferring in it's API (which is not supported by OpenAI), you can just add your own logic to handle this. I will close this issue as it's by design to not support video modal, because OpenAI does not support it, which means it's not a standard to allow video transferring in OpenAI Compatible API.