@@ -48,6 +48,7 @@ public struct CopilotModel: Codable, Equatable {
4848 public let isChatFallback : Bool
4949 public let capabilities : CopilotModelCapabilities
5050 public let billing : CopilotModelBilling ?
51+ public let customModel : CopilotModelCustomModel ?
5152 public let degradationReason : String ?
5253 public let modelPickerCategory : String ?
5354 public let modelPickerPriceCategory : String ?
@@ -73,28 +74,62 @@ public struct CopilotModelCapabilitiesLimits: Codable, Equatable {
7374public struct CopilotModelCapabilitiesSupports : Codable , Equatable {
7475 public let vision : Bool
7576 public let reasoningEfforts : [ String ] ?
76- public let supportsReasoningEffortLevel : Bool ?
77+ public let supportsReasoningEffortLevel : Bool
7778}
7879
7980public struct CopilotModelBilling : Codable , Equatable , Hashable {
8081 public let isPremium : Bool
8182 public let multiplier : Float
8283 public let tokenBasedBillingEnabled : Bool ?
8384 public let tokenPrices : CopilotModelBillingTokenPrices ?
85+ public let promo : CopilotModelBillingPromo ?
8486
85- public init ( isPremium: Bool , multiplier: Float , tokenBasedBillingEnabled: Bool ? = nil , tokenPrices: CopilotModelBillingTokenPrices ? = nil ) {
87+ public init (
88+ isPremium: Bool ,
89+ multiplier: Float ,
90+ tokenBasedBillingEnabled: Bool ? = nil ,
91+ tokenPrices: CopilotModelBillingTokenPrices ? = nil ,
92+ promo: CopilotModelBillingPromo ? = nil
93+ ) {
8694 self . isPremium = isPremium
8795 self . multiplier = multiplier
8896 self . tokenBasedBillingEnabled = tokenBasedBillingEnabled
8997 self . tokenPrices = tokenPrices
98+ self . promo = promo
9099 }
91100}
92101
93102public struct CopilotModelBillingTokenPrices : Codable , Equatable , Hashable {
103+ public let batchSize : Int ?
104+ public let `default` : CopilotModelTokenPriceTier ?
105+ public let longContext : CopilotModelTokenPriceTier ?
106+
107+ public var cachePrice : Float ? { `default`? . cachePrice ?? longContext? . cachePrice }
108+ public var inputPrice : Float ? { `default`? . inputPrice ?? longContext? . inputPrice }
109+ public var outputPrice : Float ? { `default`? . outputPrice ?? longContext? . outputPrice }
110+ public var tokenUnit : Int ? { batchSize }
111+ }
112+
113+ public struct CopilotModelTokenPriceTier : Codable , Equatable , Hashable {
94114 public let cachePrice : Float ?
115+ public let cacheWritePrice : Float ?
95116 public let inputPrice : Float ?
96117 public let outputPrice : Float ?
97- public let tokenUnit : Int ?
118+ public let maxContext : Int ?
119+ }
120+
121+ public struct CopilotModelBillingPromo : Codable , Equatable , Hashable {
122+ public let id : String
123+ public let discountPercent : Float
124+ public let endsAt : String
125+ public let message : String
126+ }
127+
128+ public struct CopilotModelCustomModel : Codable , Equatable {
129+ public let keyName : String ?
130+ public let ownerName : String ?
131+ public let ownerType : String ?
132+ public let provider : String ?
98133}
99134
100135// MARK: ChatModes
0 commit comments