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
Copy file name to clipboardExpand all lines: docs/providers/supported-providers/replicate.mdx
+99-2Lines changed: 99 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,8 @@ Replicate is architecturally different from other providers in Bifrost. It uses
23
23
| Responses API | ✅ | ✅ |`/v1/predictions`|
24
24
| Text Completions | ✅ | ✅ |`/v1/predictions`|
25
25
| Image Generation | ✅ | ✅ |`/v1/predictions`|
26
+
| Image Edit | ✅ | ✅ |`/v1/predictions`|
27
+
| Image Variation | ❌ | ❌ | - |
26
28
| Files | ✅ | - |`/v1/files`|
27
29
| List Models | ✅ | - |`/v1/deployments`|
28
30
| Embeddings | ❌ | ❌ | - |
@@ -440,7 +442,102 @@ Image generation streaming provides progressive image updates as data URIs:
440
442
441
443
---
442
444
443
-
# 5. Files API
445
+
# 5. Image Edit
446
+
447
+
Image edit runs as a prediction like image generation. You send one or more input images plus a prompt; the model returns edited image(s). The same **input image field mapping** as Image Generation applies (see [Field Mapping by Model](#field-mapping-by-model-1) below).
448
+
449
+
**Endpoint**: `/v1/images/edits` (Bifrost) → Replicate `/v1/predictions` or deployment predictions.
450
+
451
+
### Parameter Mapping
452
+
453
+
| Bifrost / Request | Replicate input |
454
+
|-------------------|-----------------|
455
+
|`input.images`| Mapped to `image_prompt`, `input_image`, `image`, or `input_images` by model |
Same as Image Generation: single URL → `data[0].url`, array of URLs → `data[i].url`, or data URIs. Response shape is `BifrostImageGenerationResponse` with `data[].url` or `data[].b64_json`.
528
+
529
+
### Streaming
530
+
531
+
Image edit streaming is supported. Events use the same prediction log stream as image generation:
532
+
533
+
-**Partial chunks**: `type: "image_edit.partial_image"` with `b64_json` (or data URI) until completion.
534
+
-**Completed**: `type: "image_edit.completed"` with final image and usage.
535
+
536
+
Use `Prefer: wait` for sync behavior or rely on polling (async) like other Replicate predictions.
537
+
538
+
---
539
+
540
+
# 6. Files API
444
541
445
542
Replicate's Files API supports uploading, listing, and managing files for use in predictions.
446
543
@@ -531,7 +628,7 @@ curl -X POST http://localhost:8080/v1/files/file_abc123/content \
0 commit comments