mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-13 07:13:48 +00:00
Keep non-chat models out of the chat lists
This commit is contained in:
11 files changed
+111
-5
No files matched your search
@@ -0,0 +1,25 @@
|
||||
using AIStudio.Provider;
|
||||
|
||||
namespace AIStudio.Models.Kinds;
|
||||
|
||||
/// <summary>
|
||||
/// The models that work a screen instead of holding a conversation.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// They are named after the chat model they grew out of -- gemini-2.5-computer-use-preview -- and a
|
||||
/// name is all they share with it. A request without the computer use tool is refused outright:
|
||||
/// "This model requires the use of the Computer Use tool." So the resemblance is exactly the trap,
|
||||
/// and this is the rule that keeps them out of the list a person picks a chat partner from.
|
||||
/// </remarks>
|
||||
public sealed class ComputerUseModelsFamily : ModelFamily
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override ModelVendor Vendor => ModelVendor.UNKNOWN;
|
||||
|
||||
/// <inheritdoc />
|
||||
public override ModelSource Source => new("https://ai.google.dev/gemini-api/docs/computer-use", new DateOnly(2026, 9, 12), "Found while testing the switch-over: the model stood in the chat list although its API refuses every request which does not carry the computer use tool.");
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Declare(ModelFamilyBuilder builder) =>
|
||||
builder.Modifier("computer-use").AsSegment().Kind(ModelKind.COMPUTER_USE);
|
||||
}
|
||||
@@ -35,5 +35,8 @@ public sealed class ImageGenerationModelsFamily : ModelFamily
|
||||
builder.Modifier("midjourney").AsSubstring().Inherits();
|
||||
|
||||
builder.Modifier("image").AsSegment().Inherits();
|
||||
|
||||
// The other half of Grok Imagine, which the video rule steps aside for:
|
||||
builder.Modifier("grok-imagine").AsSegment().NotContains("video").Inherits();
|
||||
}
|
||||
}
|
||||
@@ -23,11 +23,20 @@ public sealed class RealtimeModelsFamily : ModelFamily
|
||||
public override ModelVendor Vendor => ModelVendor.UNKNOWN;
|
||||
|
||||
/// <inheritdoc />
|
||||
public override ModelSource Source => new("https://platform.openai.com/docs/guides/realtime", new DateOnly(2026, 9, 12), "Ported from the realtime marker of Provider/ModelKindExtensions.cs, where the same precedence was written as the order of two if statements.");
|
||||
public override ModelSource Source => new("https://developers.openai.com/api/docs/models/gpt-live-1", new DateOnly(2026, 9, 12), "Ported from the realtime marker of Provider/ModelKindExtensions.cs, where the same precedence was written as the order of two if statements. GPT-Live was added after it turned up in the chat list while testing.");
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Declare(ModelFamilyBuilder builder) =>
|
||||
protected override void Declare(ModelFamilyBuilder builder)
|
||||
{
|
||||
builder.Modifier("realtime").AsSubstring()
|
||||
.Rank(1, THE_CONNECTION_DECIDES)
|
||||
.Kind(ModelKind.REALTIME);
|
||||
|
||||
//
|
||||
// The line which dropped the word. GPT-Live listens and speaks at the same time and leaves
|
||||
// the thinking to a text model behind it, so there is even less of a conversation in it than
|
||||
// in the realtime models it succeeds -- and nothing in the name says so any more.
|
||||
//
|
||||
builder.Modifier("gpt-live").AsSegment().Inherits();
|
||||
}
|
||||
}
|
||||
@@ -18,7 +18,7 @@ public sealed class VideoGenerationModelsFamily : ModelFamily
|
||||
public override ModelVendor Vendor => ModelVendor.UNKNOWN;
|
||||
|
||||
/// <inheritdoc />
|
||||
public override ModelSource Source => new("https://huggingface.co/models?pipeline_tag=text-to-video", new DateOnly(2026, 9, 12), "Ported from the video generation markers of Provider/ModelKindExtensions.cs, where veo carried a trailing hyphen to say the same thing a name part says here.");
|
||||
public override ModelSource Source => new("https://huggingface.co/models?pipeline_tag=text-to-video", new DateOnly(2026, 9, 12), "Ported from the video generation markers of Provider/ModelKindExtensions.cs, where veo carried a trailing hyphen to say the same thing a name part says here. Grok Imagine was added after it turned up in the chat list while testing; see https://docs.x.ai/docs/models.");
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Declare(ModelFamilyBuilder builder)
|
||||
@@ -32,5 +32,8 @@ public sealed class VideoGenerationModelsFamily : ModelFamily
|
||||
builder.Modifier("veo").AsSegment().Inherits();
|
||||
|
||||
builder.Modifier("kling").AsSegment().Inherits();
|
||||
|
||||
// Grok Imagine makes both stills and film; the word next to it says which:
|
||||
builder.Modifier("grok-imagine").AsSegment().AlsoContains("video").Inherits();
|
||||
}
|
||||
}
|
||||
@@ -34,6 +34,14 @@ public sealed class GrokFamily : ModelFamily
|
||||
.Capabilities(TEXT_INPUT | MULTIPLE_IMAGE_INPUT | TEXT_OUTPUT)
|
||||
.Apis(CHAT_COMPLETION_API);
|
||||
|
||||
//
|
||||
// Grok Build is the agentic coding model behind their CLI. It reads pictures, which the
|
||||
// family fallback does not know about, and it does not think out loud.
|
||||
//
|
||||
builder.Rule("grok-build").AsPrefix()
|
||||
.Capabilities(TEXT_INPUT | MULTIPLE_IMAGE_INPUT | TEXT_OUTPUT | FUNCTION_CALLING)
|
||||
.Apis(CHAT_COMPLETION_API);
|
||||
|
||||
builder.Rule("grok-3-mini").AsPrefix()
|
||||
.Capabilities(TEXT_INPUT | TEXT_OUTPUT | FUNCTION_CALLING)
|
||||
.Apis(CHAT_COMPLETION_API)
|
||||
|
||||
Reference in new issue
Block a user