/* Options: Date: 2025-01-08 03:12:06 SwiftVersion: 6.0 Version: 8.53 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://blazordiffusion.com //BaseClass: //AddModelExtensions: True //AddServiceStackTypes: True //MakePropertiesOptional: True IncludeTypes: QueryGenerationModelSettings.* //ExcludeTypes: //ExcludeGenericBaseTypes: False //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True //InitializeCollections: False //TreatTypesAsStrings: //DefaultImports: Foundation,ServiceStack */ import Foundation import ServiceStack public class QueryGenerationModelSettings : QueryDb, IReturn { public typealias Return = QueryResponse public var id:String? required public init(){ super.init() } private enum CodingKeys : String, CodingKey { case id } required public init(from decoder: Decoder) throws { try super.init(from: decoder) let container = try decoder.container(keyedBy: CodingKeys.self) id = try container.decodeIfPresent(String.self, forKey: .id) } public override func encode(to encoder: Encoder) throws { try super.encode(to: encoder) var container = encoder.container(keyedBy: CodingKeys.self) if id != nil { try container.encode(id, forKey: .id) } } } public class ProviderModelDefaults : Codable { public var id:String? public var apiModels:[String:String] = [:] public var url:String? public var quality:Double? public var aspectRatio:String? public var cfgScale:Double? public var scheduler:String? public var sampler:ComfySampler? public var width:Int? public var height:Int? public var steps:Int? public var negativePrompt:String? public var modelType:ModelType? required public init(){} } public enum ComfySampler : String, Codable { case euler case euler_cfg_pp case euler_ancestral case euler_ancestral_cfg_pp case huen case huenpp2 case dpm_2 case dpm_2_ancestral case lms case dpm_fast case dpm_adaptive case dpmpp_2s_ancestral case dpmpp_sde case dpmpp_sde_gpu case dpmpp_2m case dpmpp_2m_sde case dpmpp_2m_sde_gpu case dpmpp_3m_sde case dpmpp_3m_sde_gpu case ddpm case lcm case ddim case uni_pc case uni_pc_bh2 } public enum ModelType : String, Codable { case TextToImage case TextEncoder case ImageUpscale case TextToSpeech case TextToAudio case SpeechToText case ImageToText case ImageToImage case ImageWithMask case VAE }