Demo to preview the plugin:

Introduction

The Replicate AI plugin enables you to harness the power of the Replicate AI platform and its models for advanced machine-learning tasks. This plugin allows you to generate, manage, and retrieve predictions using various AI models hosted on Replicate.
💡
Every time you run a model, you're creating a prediction. A prediction is the result generated by an AI model in response to specific inputs provided by the user. It involves processing the input data—such as a text prompt, image, or other parameters—through a trained model to produce an output.
💡
Input and output (including any files) are automatically deleted after an hour for any predictions created through the API, so you must save a copy of any files in the output if you'd like to continue using them.
Some models execute rapidly and may provide results in just a few milliseconds. However, more complex models, such as those generating images from text prompts, may require significantly more time to complete.
To handle this effectively:
  • Wait for Response: You can configure the action to wait for the response. While this works well for faster predictions, it may not suffice for models that take longer to process.
  • Using a Webhook: For lengthy predictions, it is highly recommended to provide a webhook URL. This allows the model to send updates to your server as soon as the prediction is ready, ensuring you don't miss the result.
  • Manual Retrieval: If you prefer not to use a webhook or are unable to, you can manually query the prediction status later to retrieve the output once it's completed.

Available Models In The Plugin

  • A generative model for creating high-quality images from textual prompts.
  • Use Case: Generating artistic, photorealistic, or abstract visuals.
  • A generative model designed to enhance and restore facial features in images.
  • Use Case: Improving image quality, restoring old or damaged photos.

3. SDXL

  • An advanced version of the Stable Diffusion model with extended capabilities.
  • Use Case: Producing ultra-high-resolution images with finer details.
  • A model specialized in generating music or audio based on input prompts and references.
  • Use Case: Composing music tracks or audio samples.
  • A premium model for advanced generative tasks requiring high fidelity and precision.
  • Use Case: Creating cutting-edge visuals, animations, or simulations.

Prerequisites

You must have a Replicate AI with a billing set.
💡
To create a Replicate AI account, you first need to have a GitHub account. After setting up your GitHub account, you can sign up for Replicate AI using GitHub for authentication.
Image without caption

How to setup

  1. Create an account on Replicate AI or sign in to an existing one.
2. Set up the billing for the account, in the account “Setting” tab → “Billing” section.
Image without caption
Image without caption
  1. Go to “API tokens” tab and create a token.
Image without caption
  1. Copy the token and set it up in the plugin settings on bubble page for secure usage of the Replicate AI.
Image without caption

Plugin Data/Action Calls (API Calls only)

Create Prediction - Stable Diffusion

Create Prediction - GFPGAN

Create Prediction - SDXL

Create Prediction - Music-01

Create Prediction - FLUX 1.1 [Pro]

Get Prediction

Cancel Prediction

List Predictions

How To Set Up The Webhooks

💡
Webhook URL is used to receive updates about the status of a prediction, such as completion or failure, without the need for continuous polling. When a webhook URL is provided, the service will send an HTTP POST request to the specified URL containing the prediction status and results.
  1. In your bubble app → Backend Workflows create a “New API workflow”
    1. Image without caption
  1. Give it a name and set it up like in the image
    1. Image without caption
  1. Click on “Detect data” button and copy the link from the screen.
    1. Image without caption
      Image without caption
  1. Meanwhile in a new tab while this tab is still open and detecting, create any prediction with the plugin that has this copied URL set up as the webhook URL.
    1. Image without caption
  1. When the prediction is created, the data will be detected in backend workflows. Now every prediction that has this URL when created will be triggered on updates in backend workflow.
    1. Image without caption
Image without caption

Changelogs