You're looking at a specific version of this model. Jump to the model overview.
Text to prefix with 'hello '
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import Replicate from "replicate"; const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN, });
Run replicate/hello-world using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run( "replicate/hello-world:5c7d5dc6dd8bf75c1acaa8565735e7986bc5b66206b55cca93cb72c9bf15ccaa", { input: { text: "Zephyr" } } ); console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
import replicate
output = replicate.run( "replicate/hello-world:5c7d5dc6dd8bf75c1acaa8565735e7986bc5b66206b55cca93cb72c9bf15ccaa", input={ "text": "Zephyr" } ) print(output)
To learn more, take a look at the guide on getting started with Python.
curl -s -X POST \ -H "Authorization: Bearer $REPLICATE_API_TOKEN" \ -H "Content-Type: application/json" \ -H "Prefer: wait" \ -d $'{ "version": "replicate/hello-world:5c7d5dc6dd8bf75c1acaa8565735e7986bc5b66206b55cca93cb72c9bf15ccaa", "input": { "text": "Zephyr" } }' \ https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{ "completed_at": "2022-04-26T19:30:30.089041Z", "created_at": "2022-04-26T19:30:29.918337Z", "data_removed": false, "error": null, "id": "ijy6iwuupvguxlj5llclzzk6ta", "input": { "text": "Zephyr" }, "logs": null, "metrics": { "predict_time": 0.000001, "total_time": 0.170704 }, "output": "hello Zephyr", "started_at": "2022-04-26T19:30:30.089040Z", "status": "succeeded", "urls": { "get": "https://api.replicate.com/v1/predictions/ijy6iwuupvguxlj5llclzzk6ta", "cancel": "https://api.replicate.com/v1/predictions/ijy6iwuupvguxlj5llclzzk6ta/cancel" }, "version": "5c7d5dc6dd8bf75c1acaa8565735e7986bc5b66206b55cca93cb72c9bf15ccaa" }