2025-11-13 17:13:16 +00:00
|
|
|
|
using AIStudio.Provider;
|
|
|
|
|
|
|
|
|
|
|
|
namespace AIStudio.Settings;
|
|
|
|
|
|
|
|
|
|
|
|
public static partial class ProviderExtensions
|
|
|
|
|
|
{
|
2025-12-30 17:30:32 +00:00
|
|
|
|
private static List<Capability> GetModelCapabilitiesDeepSeek(Model model)
|
2025-11-13 17:13:16 +00:00
|
|
|
|
{
|
|
|
|
|
|
var modelName = model.Id.ToLowerInvariant().AsSpan();
|
|
|
|
|
|
|
2026-08-29 14:07:00 +00:00
|
|
|
|
// The reasoner alias points to the thinking mode of the current flash model:
|
2025-11-13 17:13:16 +00:00
|
|
|
|
if(modelName.IndexOf("reasoner") is not -1)
|
|
|
|
|
|
return
|
|
|
|
|
|
[
|
|
|
|
|
|
Capability.TEXT_INPUT,
|
|
|
|
|
|
Capability.TEXT_OUTPUT,
|
2026-08-29 14:07:00 +00:00
|
|
|
|
|
|
|
|
|
|
Capability.ALWAYS_REASONING, Capability.FUNCTION_CALLING,
|
2025-11-13 17:13:16 +00:00
|
|
|
|
Capability.CHAT_COMPLETION_API,
|
|
|
|
|
|
];
|
2026-08-29 14:07:00 +00:00
|
|
|
|
|
|
|
|
|
|
// The chat alias points to the non-thinking mode of the same model:
|
|
|
|
|
|
if(modelName.IndexOf("chat") is not -1)
|
|
|
|
|
|
return
|
|
|
|
|
|
[
|
|
|
|
|
|
Capability.TEXT_INPUT,
|
|
|
|
|
|
Capability.TEXT_OUTPUT,
|
|
|
|
|
|
|
|
|
|
|
|
Capability.FUNCTION_CALLING,
|
|
|
|
|
|
Capability.CHAT_COMPLETION_API,
|
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
// DeepSeek publishes its models as open weights and offers them under the same
|
|
|
|
|
|
// names here. Instead of maintaining a second copy of those rules, we reuse the
|
|
|
|
|
|
// ones for open source models:
|
|
|
|
|
|
return GetModelCapabilitiesOpenSource(model);
|
2025-11-13 17:13:16 +00:00
|
|
|
|
}
|
|
|
|
|
|
}
|