You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* @param {string} identifier - Required. The model version identifier in the format "{owner}/{name}:{version}"
95
+
* @param {string} ref - Required. The model version identifier in the format "owner/name" or "owner/name:version"
95
96
* @param {object} options
96
97
* @param {object} options.input - Required. An object with the model inputs
97
98
* @param {object} [options.wait] - Options for waiting for the prediction to finish
@@ -100,37 +101,29 @@ class Replicate {
100
101
* @param {string[]} [options.webhook_events_filter] - You can change which events trigger webhook requests by specifying webhook events (`start`|`output`|`logs`|`completed`)
101
102
* @param {AbortSignal} [options.signal] - AbortSignal to cancel the prediction
102
103
* @param {Function} [progress] - Callback function that receives the prediction object as it's updated. The function is called when the prediction is created, each time its updated while polling for completion, and when it's completed.
104
+
* @throws {Error} If the reference is invalid
103
105
* @throws {Error} If the prediction failed
104
106
* @returns {Promise<object>} - Resolves with the output of running the model
105
107
*/
106
-
asyncrun(identifier,options,progress){
108
+
asyncrun(ref,options,progress){
107
109
const{ wait, ...data}=options;
108
110
109
-
// Define a pattern for owner and model names that allows
110
-
// letters, digits, and certain special characters.
0 commit comments