mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-17 22:37:59 +00:00
Port the Alibaba Cloud families and refuse ambiguous rule inheritance
This commit is contained in:
10 files changed
+285
-3
No files matched your search
@@ -0,0 +1,32 @@
|
||||
using AIStudio.Provider;
|
||||
|
||||
using static AIStudio.Provider.Capability;
|
||||
|
||||
namespace AIStudio.Models.Alibaba;
|
||||
|
||||
/// <summary>
|
||||
/// The Qwen Omni models, which take everything in and answer in text or in speech.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Alibaba lists the Qwen3 Omni series among the models which call functions and leaves the older
|
||||
/// ones off that list, which is the whole difference between the two rules below.
|
||||
/// </remarks>
|
||||
public sealed class ModelStudioQwenOmniFamily : ModelFamily
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override ModelVendor Vendor => ModelVendor.ALIBABA;
|
||||
|
||||
/// <inheritdoc />
|
||||
public override ModelSource Source => new("https://www.alibabacloud.com/help/en/model-studio/models", new DateOnly(2026, 9, 11), "Ported unchanged from the rules in ProviderExtensions.Alibaba.cs: every modality in, text and speech out, tool calling from Qwen3 on.");
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Declare(ModelFamilyBuilder builder)
|
||||
{
|
||||
builder.Rule("qwen").AsSubstring().AlsoContains("omni").OnlyOn(LLMProviders.ALIBABA_CLOUD)
|
||||
.Capabilities(TEXT_INPUT | MULTIPLE_IMAGE_INPUT | AUDIO_INPUT | SPEECH_INPUT | VIDEO_INPUT | TEXT_OUTPUT | SPEECH_OUTPUT)
|
||||
.Apis(CHAT_COMPLETION_API);
|
||||
|
||||
builder.Rule("qwen3").AsPrefix().AlsoContains("omni").OnlyOn(LLMProviders.ALIBABA_CLOUD).Inherits()
|
||||
.Capabilities(FUNCTION_CALLING);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user