mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-04 21:27:21 +00:00
Allowed the Batch Processing assistant to process images (#1087)
Co-authored-by: Thorsten Sommer <SommerEngineering@users.noreply.github.com>
This commit is contained in:
1 parent
5d6e48ef93
commit
e019c24ea2
19 files changed
+429
-31
No files matched your search
@@ -11,7 +11,7 @@ namespace AIStudio.Settings.DataModel;
|
||||
/// <param name="configSelection">The managed-configuration selector.</param>
|
||||
public sealed class DataBatchProcessing(Expression<Func<Data, DataBatchProcessing>>? configSelection = null)
|
||||
{
|
||||
public const string DEFAULT_FILE_PATTERNS = "*.pdf;*.docx;*.pptx;*.xlsx;*.md;*.txt;*.mp3;*.wav;*.wave;*.aac;*.flac;*.ogg;*.opus;*.m4a;*.m4b;*.wma;*.alac;*.aif;*.aiff;*.caf;*.mp4;*.m4v;*.avi;*.mkv;*.mov;*.wmv;*.flv;*.webm";
|
||||
public const string DEFAULT_FILE_PATTERNS = "*.pdf;*.docx;*.pptx;*.xlsx;*.md;*.txt;*.jpg;*.jpeg;*.png;*.webp;*.gif;*.mp3;*.wav;*.wave;*.aac;*.flac;*.ogg;*.opus;*.m4a;*.m4b;*.wma;*.alac;*.aif;*.aiff;*.caf;*.mp4;*.m4v;*.avi;*.mkv;*.mov;*.wmv;*.flv;*.webm";
|
||||
public const int MIN_DELAY_SECONDS = 6;
|
||||
public const int MAX_DELAY_SECONDS = 300;
|
||||
public const int DEFAULT_MIN_DELAY_SECONDS = 6;
|
||||
|
||||
@@ -81,10 +81,17 @@ public static partial class ProviderExtensions
|
||||
/// wants to know whether an image may be sent has to accept both, which is why the question is asked
|
||||
/// here instead of at each call site: attaching a file and validating an already attached file must
|
||||
/// never disagree about it.
|
||||
///
|
||||
/// A limit of zero images takes the capability back. Zero is a real answer, e.g., from an operator
|
||||
/// whose engine accepts no images at all, see ImageLimits; an unknown limit says nothing.
|
||||
/// </remarks>
|
||||
/// <param name="provider">The configured provider.</param>
|
||||
/// <returns><c>true</c> when the model accepts image input.</returns>
|
||||
public static bool SupportsImageInput(this Provider provider) => provider.GetModelProfile().HasAny(Capability.SINGLE_IMAGE_INPUT | Capability.MULTIPLE_IMAGE_INPUT);
|
||||
public static bool SupportsImageInput(this Provider provider)
|
||||
{
|
||||
var profile = provider.GetModelProfile();
|
||||
return profile.HasAny(Capability.SINGLE_IMAGE_INPUT | Capability.MULTIPLE_IMAGE_INPUT) && profile.Images.MaxInOneMessage is not 0;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Checks whether this model can be used for chatting.
|
||||
|
||||
Reference in new issue
Block a user