defaultAn astronaut riding a rainbow unicorn
typetext
{
"apply_watermark": true,
"guidance_scale": 7.5,
"height": 1024,
"high_noise_frac": 0.8,
"lora_scale": 0.6,
"negative_prompt": "",
"num_inference_steps": 50,
"num_outputs": 1,
"prompt": "In the style of TOK, a photo of a modern kitchen, white marble, large island",
"prompt_strength": 0.8,
"refine": "no_refiner",
"scheduler": "K_EULER",
"width": 1024
}npm install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_Z5P**********************************
This is your API token. Keep it to yourself.
import Replicate from "replicate";
import fs from "node:fs";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run sidhq/vzug using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"sidhq/vzug:49e0e9370b5361ffd56e753209b065f8d0d55f754cd404784c1b136595f90911",
{
input: {
apply_watermark: true,
guidance_scale: 7.5,
height: 1024,
high_noise_frac: 0.8,
lora_scale: 0.6,
negative_prompt: "",
num_inference_steps: 50,
num_outputs: 1,
prompt: "In the style of TOK, a photo of a modern kitchen, white marble, large island",
prompt_strength: 0.8,
refine: "no_refiner",
scheduler: "K_EULER",
width: 1024
}
}
);
// To access the file URL:
console.log(output[0].url()); //=> "http://example.com"
// To write the file to disk:
fs.writeFile("my-image.png", output[0]);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_Z5P**********************************
This is your API token. Keep it to yourself.
import replicate
Run sidhq/vzug using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"sidhq/vzug:49e0e9370b5361ffd56e753209b065f8d0d55f754cd404784c1b136595f90911",
input={
"apply_watermark": True,
"guidance_scale": 7.5,
"height": 1024,
"high_noise_frac": 0.8,
"lora_scale": 0.6,
"negative_prompt": "",
"num_inference_steps": 50,
"num_outputs": 1,
"prompt": "In the style of TOK, a photo of a modern kitchen, white marble, large island",
"prompt_strength": 0.8,
"refine": "no_refiner",
"scheduler": "K_EULER",
"width": 1024
}
)
# To access the file URL:
print(output[0].url())
#=> "http://example.com"
# To write the file to disk:
with open("my-image.png", "wb") as file:
file.write(output[0].read())
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_Z5P**********************************
This is your API token. Keep it to yourself.
Run sidhq/vzug using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"version": "sidhq/vzug:49e0e9370b5361ffd56e753209b065f8d0d55f754cd404784c1b136595f90911",
"input": {
"apply_watermark": true,
"guidance_scale": 7.5,
"height": 1024,
"high_noise_frac": 0.8,
"lora_scale": 0.6,
"negative_prompt": "",
"num_inference_steps": 50,
"num_outputs": 1,
"prompt": "In the style of TOK, a photo of a modern kitchen, white marble, large island",
"prompt_strength": 0.8,
"refine": "no_refiner",
"scheduler": "K_EULER",
"width": 1024
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{
"id": "qrz7cc3bfyjqllqnf5iuhnlafq",
"model": "sidhq/vzug",
"version": "49e0e9370b5361ffd56e753209b065f8d0d55f754cd404784c1b136595f90911",
"input": {
"apply_watermark": true,
"guidance_scale": 7.5,
"height": 1024,
"high_noise_frac": 0.8,
"lora_scale": 0.6,
"negative_prompt": "",
"num_inference_steps": 50,
"num_outputs": 1,
"prompt": "In the style of TOK, a photo of a modern kitchen, white marble, large island",
"prompt_strength": 0.8,
"refine": "no_refiner",
"scheduler": "K_EULER",
"width": 1024
},
"logs": "",
"output": [
"https://pbxt.replicate.delivery/aybHGRPNFjbaLhU1Yx6f4xenBWCp33AXoTf2PVVg9JewmRuGB/out-0.png"
],
"data_removed": false,
"error": null,
"source": "web",
"status": "succeeded",
"created_at": "2023-10-06T23:12:27.211485Z",
"started_at": "2023-10-06T23:12:28.52321Z",
"completed_at": "2023-10-06T23:12:44.965987Z",
"urls": {
"cancel": "https://api.replicate.com/v1/predictions/qrz7cc3bfyjqllqnf5iuhnlafq/cancel",
"get": "https://api.replicate.com/v1/predictions/qrz7cc3bfyjqllqnf5iuhnlafq"
},
"metrics": {
"predict_time": 16.442777,
"total_time": 17.754502
}
}