2025-03-31 20:16:46 +00:00
|
|
|
using BotSharp.Abstraction.Instructs.Models;
|
|
|
|
|
|
2024-08-07 21:56:57 +00:00
|
|
|
namespace BotSharp.Abstraction.Files;
|
|
|
|
|
|
|
|
|
|
public interface IFileInstructService
|
|
|
|
|
{
|
|
|
|
|
#region Image
|
2025-03-31 20:16:46 +00:00
|
|
|
Task<string> ReadImages(string text, IEnumerable<InstructFileModel> images, InstructOptions? options = null);
|
|
|
|
|
Task<RoleDialogModel> GenerateImage(string text, InstructOptions? options = null);
|
|
|
|
|
Task<RoleDialogModel> VaryImage(InstructFileModel image, InstructOptions? options = null);
|
|
|
|
|
Task<RoleDialogModel> EditImage(string text, InstructFileModel image, InstructOptions? options = null);
|
|
|
|
|
Task<RoleDialogModel> EditImage(string text, InstructFileModel image, InstructFileModel mask, InstructOptions? options = null);
|
2025-10-15 01:28:09 +00:00
|
|
|
Task<RoleDialogModel> ComposeImages(string text, InstructFileModel[] images, InstructOptions? options = null);
|
2024-08-07 21:56:57 +00:00
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region Pdf
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Take screenshots of pdf pages and get response from llm
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="prompt"></param>
|
|
|
|
|
/// <param name="files">Pdf files</param>
|
|
|
|
|
/// <returns></returns>
|
2025-03-31 20:16:46 +00:00
|
|
|
Task<string> ReadPdf(string text, List<InstructFileModel> files, InstructOptions? options = null);
|
2024-08-07 21:56:57 +00:00
|
|
|
#endregion
|
|
|
|
|
|
2024-08-26 22:24:07 +00:00
|
|
|
#region Audio
|
2025-03-31 20:16:46 +00:00
|
|
|
Task<string> SpeechToText(InstructFileModel audio, string? text = null, InstructOptions? options = null);
|
2024-08-26 22:24:07 +00:00
|
|
|
#endregion
|
|
|
|
|
|
2024-08-07 21:56:57 +00:00
|
|
|
#region Select file
|
2024-08-08 00:26:22 +00:00
|
|
|
Task<IEnumerable<MessageFileModel>> SelectMessageFiles(string conversationId, SelectFileOptions options);
|
2024-08-07 21:56:57 +00:00
|
|
|
#endregion
|
|
|
|
|
}
|