File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -128,10 +128,6 @@ export class Model implements IModel {
128128 * @param progressCallbackOrSignal - Optional progress callback or AbortSignal.
129129 * @param signal - Optional AbortSignal when a progress callback is provided.
130130 */
131- public download ( progressCallback ?: ( progress : number ) => void ) : Promise < void > ;
132- public download ( signal : AbortSignal ) : Promise < void > ;
133- public download ( progressCallback : undefined , signal : AbortSignal ) : Promise < void > ;
134- public download ( progressCallback : ( progress : number ) => void , signal : AbortSignal ) : Promise < void > ;
135131 public download (
136132 progressCallbackOrSignal ?: ( ( progress : number ) => void ) | AbortSignal ,
137133 signal ?: AbortSignal
Original file line number Diff line number Diff line change @@ -110,10 +110,6 @@ export class ModelVariant implements IModel {
110110 * @param progressCallbackOrSignal - Optional progress callback (0-100) or AbortSignal.
111111 * @param signal - Optional AbortSignal when a progress callback is provided.
112112 */
113- public download ( progressCallback ?: ( progress : number ) => void ) : Promise < void > ;
114- public download ( signal : AbortSignal ) : Promise < void > ;
115- public download ( progressCallback : undefined , signal : AbortSignal ) : Promise < void > ;
116- public download ( progressCallback : ( progress : number ) => void , signal : AbortSignal ) : Promise < void > ;
117113 public async download (
118114 progressCallbackOrSignal ?: ( ( progress : number ) => void ) | AbortSignal ,
119115 signal ?: AbortSignal
Original file line number Diff line number Diff line change @@ -19,20 +19,11 @@ export interface IModel {
1919
2020 /**
2121 * Download the model to local cache if not already present.
22- * @param progressCallback - Optional callback for download progress (0-100).
22+ * @param progressCallbackOrSignal - Optional callback for download progress (0-100), or AbortSignal.
23+ * @param signal - Optional AbortSignal when a progress callback is provided.
2324 */
24- download ( progressCallback ?: ( progress : number ) => void ) : Promise < void > ;
25- /**
26- * Download the model to local cache if not already present.
27- * @param signal - AbortSignal. When aborted, the download will be cancelled at the next progress update.
28- */
29- download ( signal : AbortSignal ) : Promise < void > ;
30- /**
31- * Download the model to local cache if not already present.
32- * @param progressCallback - Optional callback for download progress (0-100).
33- */
34- download ( progressCallback : undefined , signal : AbortSignal ) : Promise < void > ;
35- download ( progressCallback : ( progress : number ) => void , signal : AbortSignal ) : Promise < void > ;
25+ download ( progressCallbackOrSignal ?: ( ( progress : number ) => void ) | AbortSignal ,
26+ signal ?: AbortSignal ) : Promise < void > ;
3627 get path ( ) : string ;
3728 load ( ) : Promise < void > ;
3829 removeFromCache ( ) : void ;
You can’t perform that action at this time.
0 commit comments