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
|`options.webhook`| string | An HTTPS URL for receiving a webhook when the prediction has new output |
168
168
|`options.webhook_events_filter`| string[]| An array of events which should trigger [webhooks](https://replicate.com/docs/webhooks). Allowable values are `start`, `output`, `logs`, and `completed`|
169
169
|`options.signal`| object | An [AbortSignal](https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal) to cancel the prediction |
170
-
|`progress`| function | 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. |
170
+
|`progress`| function | Callback function that receives the prediction object as it's updated. The function is called when the prediction is created, each time it's updated while polling for completion, and when it's completed. |
171
171
172
172
Throws `Error` if the prediction failed.
173
173
@@ -181,6 +181,18 @@ const input = { prompt: "a 19th century portrait of a raccoon gentleman wearing
181
181
constoutput=awaitreplicate.run(model, { input });
182
182
```
183
183
184
+
Example that logs progress as the model is running:
Run a model and stream its output. Unlike [`replicate.prediction.create`](#replicatepredictionscreate), this method returns only the prediction output rather than the entire prediction object.
0 commit comments